@kong-ui-public/entities-consumer-credentials 2.1.59 → 2.1.60

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,4 +1,4 @@
1
- import { defineComponent as ie, ref as v, computed as N, watch as oe, renderSlot as Y, createCommentVNode as V, unref as m, resolveComponent as L, openBlock as j, createBlock as J, withCtx as s, createVNode as g, createSlots as Te, withDirectives as Ne, createElementVNode as ee, createElementBlock as G, vShow as Ie, renderList as xe, createTextVNode as D, toDisplayString as x, inject as Be, onMounted as qe, onUnmounted as ze, onBeforeMount as Je, resolveDynamicComponent as We, Fragment as He, withModifiers as Ye } from "vue";
1
+ import { defineComponent as ie, ref as v, computed as N, watch as oe, renderSlot as Y, createCommentVNode as V, unref as m, resolveComponent as L, openBlock as j, createBlock as J, withCtx as s, createVNode as g, createSlots as Te, withDirectives as Ne, createElementVNode as ee, createElementBlock as G, vShow as Ie, renderList as xe, createTextVNode as U, toDisplayString as x, inject as Be, onMounted as qe, onUnmounted as ze, onBeforeMount as Je, resolveDynamicComponent as We, Fragment as He, withModifiers as Ye } from "vue";
2
2
  import { createI18n as Ee, i18nTComponent as Oe } from "@kong-ui-public/i18n";
3
3
  import me from "axios";
4
4
  import "@kong/kongponents";
@@ -408,10 +408,10 @@ function yt(e, r, t, a = {
408
408
  headers: e.requestHeaders
409
409
  }), { i18n: { t: l } } = pe(), { debounce: i } = tt(), o = i(async (w) => {
410
410
  await ae(w);
411
- }, 200), c = v(!1), p = v(""), b = v(""), y = v([]), A = v([]), _ = v(void 0), U = m(r);
412
- let f = `${e.apiBaseUrl}${U}`;
411
+ }, 200), c = v(!1), p = v(""), b = v(""), y = v([]), A = v([]), _ = v(void 0), R = m(r);
412
+ let f = `${e.apiBaseUrl}${R}`;
413
413
  e.app === "konnect" ? f = f.replace(/{controlPlaneId}/gi, (e == null ? void 0 : e.controlPlaneId) || "") : e.app === "kongManager" && (f = f.replace(/\/{workspace}/gi, e != null && e.workspace ? `/${e.workspace}` : ""));
414
- const { isValidUuid: T } = Ke(), F = async () => {
414
+ const { isValidUuid: T } = Ke(), P = async () => {
415
415
  try {
416
416
  c.value = !0;
417
417
  const { data: w } = await n.get(`${f}?size=${t}`);
@@ -422,7 +422,7 @@ function yt(e, r, t, a = {
422
422
  c.value = !1;
423
423
  }
424
424
  }, Z = v(""), ae = async (w) => {
425
- var u, k, q;
425
+ var u, C, q;
426
426
  if (Z.value !== w)
427
427
  if (Z.value = w || "", _.value === void 0)
428
428
  try {
@@ -445,14 +445,14 @@ function yt(e, r, t, a = {
445
445
  const K = await Promise.all(E), z = /* @__PURE__ */ new Set();
446
446
  y.value = [], (u = K == null ? void 0 : K.forEach) == null || u.call(K, (I) => {
447
447
  var O;
448
- (O = I == null ? void 0 : I.forEach) == null || O.call(I, (R) => {
449
- z.has(R.id) || (z.add(R.id), y.value.push(R));
448
+ (O = I == null ? void 0 : I.forEach) == null || O.call(I, (B) => {
449
+ z.has(B.id) || (z.add(B.id), y.value.push(B));
450
450
  });
451
451
  });
452
452
  } else
453
453
  y.value = A.value;
454
454
  } catch (E) {
455
- ((k = E == null ? void 0 : E.response) == null ? void 0 : k.status) === 404 ? b.value = l("debouncedFilter.errors.invalid") : (y.value = [], p.value = l("debouncedFilter.errors.fetch"));
455
+ ((C = E == null ? void 0 : E.response) == null ? void 0 : C.status) === 404 ? b.value = l("debouncedFilter.errors.invalid") : (y.value = [], p.value = l("debouncedFilter.errors.fetch"));
456
456
  } finally {
457
457
  c.value = !1;
458
458
  }
@@ -473,7 +473,7 @@ function yt(e, r, t, a = {
473
473
  validationError: b,
474
474
  results: y,
475
475
  allRecords: _,
476
- loadItems: F,
476
+ loadItems: P,
477
477
  debouncedQueryChange: o
478
478
  };
479
479
  }
@@ -534,8 +534,8 @@ function $e(e, r) {
534
534
  const { page: o, pageSize: c, offset: p, sortColumnKey: b, sortColumnOrder: y, query: A } = i;
535
535
  try {
536
536
  let _ = new URL(l.value.href);
537
- return n.value && A ? (_.search = "", _ = t.value.app === "konnect" ? new URL(`${_.href}?filter[name][contains]=${A}`) : new URL(`${_.href}/${A}/`)) : (n.value || new URLSearchParams(A).forEach((U, f) => {
538
- _.searchParams.append(f, U);
537
+ return n.value && A ? (_.search = "", _ = t.value.app === "konnect" ? new URL(`${_.href}?filter[name][contains]=${A}`) : new URL(`${_.href}/${A}/`)) : (n.value || new URLSearchParams(A).forEach((R, f) => {
538
+ _.searchParams.append(f, R);
539
539
  }), b && _.searchParams.append("sort_by", b), y === "desc" && _.searchParams.append("sort_desc", "1"), _.searchParams.append("size", String(c))), p && o !== 1 && _.searchParams.append("offset", String(p)), _.href;
540
540
  } catch (_) {
541
541
  return console.error("RouteList(fetcher)", _), a.value;
@@ -593,10 +593,10 @@ function bt() {
593
593
  convertKeyToTitle: e
594
594
  };
595
595
  }
596
- const Pe = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, ve = (e) => {
596
+ const Fe = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i, ve = (e) => {
597
597
  if (typeof e != "string")
598
598
  throw new TypeError("Invalid argument expected string");
599
- const r = e.match(Pe);
599
+ const r = e.match(Fe);
600
600
  if (!r)
601
601
  throw new Error(`Invalid argument not valid semver ('${e}' received)`);
602
602
  return r.shift(), r;
@@ -621,20 +621,20 @@ const Pe = /^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-(
621
621
  }, Ce = (e, r, t) => {
622
622
  _t(t);
623
623
  const a = Ct(e, r);
624
- return Fe[t].includes(a);
625
- }, Fe = {
624
+ return Pe[t].includes(a);
625
+ }, Pe = {
626
626
  ">": [1],
627
627
  ">=": [0, 1],
628
628
  "=": [0],
629
629
  "<=": [-1, 0],
630
630
  "<": [-1],
631
631
  "!=": [-1, 1]
632
- }, _e = Object.keys(Fe), _t = (e) => {
632
+ }, _e = Object.keys(Pe), _t = (e) => {
633
633
  if (typeof e != "string")
634
634
  throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);
635
635
  if (_e.indexOf(e) === -1)
636
636
  throw new Error(`Invalid operator, expected one of ${_e.join("|")}`);
637
- }, St = (e) => typeof e == "string" && /^[v\d]/.test(e) && Pe.test(e);
637
+ }, St = (e) => typeof e == "string" && /^[v\d]/.test(e) && Fe.test(e);
638
638
  function At(e) {
639
639
  const { gatewayInfo: r, supportedRange: t } = e;
640
640
  if (!r)
@@ -701,11 +701,11 @@ function Ot(e, r) {
701
701
  function jt(e) {
702
702
  return e === 0 && Number.NEGATIVE_INFINITY === 1 / e;
703
703
  }
704
- var Kt = Le, $t = It, Pt = xt, Ft = Ot, Lt = jt, Mt = Et, he = {
704
+ var Kt = Le, $t = It, Ft = xt, Pt = Ot, Lt = jt, Mt = Et, he = {
705
705
  isNothing: Kt,
706
706
  isObject: $t,
707
- toArray: Pt,
708
- repeat: Ft,
707
+ toArray: Ft,
708
+ repeat: Pt,
709
709
  isNegativeZero: Lt,
710
710
  extend: Mt
711
711
  };
@@ -1169,13 +1169,13 @@ var $r = new $("tag:yaml.org,2002:omap", {
1169
1169
  kind: "sequence",
1170
1170
  resolve: jr,
1171
1171
  construct: Kr
1172
- }), Pr = Object.prototype.toString;
1173
- function Fr(e) {
1172
+ }), Fr = Object.prototype.toString;
1173
+ function Pr(e) {
1174
1174
  if (e === null)
1175
1175
  return !0;
1176
1176
  var r, t, a, n, l, i = e;
1177
1177
  for (l = new Array(i.length), r = 0, t = i.length; r < t; r += 1) {
1178
- if (a = i[r], Pr.call(a) !== "[object Object]" || (n = Object.keys(a), n.length !== 1))
1178
+ if (a = i[r], Fr.call(a) !== "[object Object]" || (n = Object.keys(a), n.length !== 1))
1179
1179
  return !1;
1180
1180
  l[r] = [n[0], a[n[0]]];
1181
1181
  }
@@ -1191,7 +1191,7 @@ function Lr(e) {
1191
1191
  }
1192
1192
  var Mr = new $("tag:yaml.org,2002:pairs", {
1193
1193
  kind: "sequence",
1194
- resolve: Fr,
1194
+ resolve: Pr,
1195
1195
  construct: Lr
1196
1196
  }), Dr = Object.prototype.hasOwnProperty;
1197
1197
  function Ur(e) {
@@ -1254,15 +1254,15 @@ const Jr = {
1254
1254
  return ((f = t.value) == null ? void 0 : f.querySelector('[data-testid="first-col"]')) || null;
1255
1255
  }), n = N(() => {
1256
1256
  var f, T;
1257
- const F = (f = r.rowEl) == null ? void 0 : f.querySelectorAll("td");
1258
- return F ? ((T = F[0]) == null ? void 0 : T.getAttribute("data-testid")) === r.keyName : !1;
1257
+ const P = (f = r.rowEl) == null ? void 0 : f.querySelectorAll("td");
1258
+ return P ? ((T = P[0]) == null ? void 0 : T.getAttribute("data-testid")) === r.keyName : !1;
1259
1259
  });
1260
1260
  let l;
1261
1261
  const i = () => {
1262
1262
  l && (l.disconnect(), l = void 0);
1263
1263
  }, o = () => {
1264
- var f, T, F;
1265
- p.value = ((f = a.value) == null ? void 0 : f.getBoundingClientRect().width) || 0, b.value = ((T = t.value) == null ? void 0 : T.clientWidth) || 0, y.value = ((F = c.value) == null ? void 0 : F.innerText) || "";
1264
+ var f, T, P;
1265
+ p.value = ((f = a.value) == null ? void 0 : f.getBoundingClientRect().width) || 0, b.value = ((T = t.value) == null ? void 0 : T.clientWidth) || 0, y.value = ((P = c.value) == null ? void 0 : P.innerText) || "";
1266
1266
  }, c = v({}), p = v(0), b = v(0), y = v(""), A = N(() => [a.value, t.value]), _ = oe(
1267
1267
  A,
1268
1268
  (f) => {
@@ -1277,23 +1277,23 @@ const Jr = {
1277
1277
  }
1278
1278
  },
1279
1279
  { immediate: !0, flush: "post", deep: !0 }
1280
- ), U = N(() => n.value ? p.value > b.value : !1);
1280
+ ), R = N(() => n.value ? p.value > b.value : !1);
1281
1281
  return qe(() => {
1282
1282
  o();
1283
1283
  }), ze(() => {
1284
1284
  _();
1285
1285
  }), (f, T) => {
1286
- const F = L("KTooltip");
1286
+ const P = L("KTooltip");
1287
1287
  return j(), G("span", {
1288
1288
  ref_key: "contentRef",
1289
1289
  ref: c,
1290
1290
  class: "content-wrapper"
1291
1291
  }, [
1292
1292
  n.value ? (j(), G("span", Jr, [
1293
- g(F, {
1293
+ g(P, {
1294
1294
  "max-width": "300",
1295
1295
  placement: "bottomStart",
1296
- text: U.value ? y.value : ""
1296
+ text: R.value ? y.value : ""
1297
1297
  }, {
1298
1298
  default: s(() => [
1299
1299
  Y(f.$slots, "default", {}, void 0, !0)
@@ -1418,7 +1418,7 @@ const Jr = {
1418
1418
  emits: ["click:row", "sort", "clear-search-input", "empty-state-cta-clicked"],
1419
1419
  setup(e, { emit: r }) {
1420
1420
  const t = e, a = r, { i18n: { t: n } } = fe.useI18n(), l = N(() => {
1421
- var u, k;
1421
+ var u, C;
1422
1422
  return typeof t.errorMessage == "string" ? {
1423
1423
  hasError: !!t.errorMessage,
1424
1424
  title: t.errorMessage,
@@ -1426,15 +1426,15 @@ const Jr = {
1426
1426
  } : {
1427
1427
  hasError: !!t.errorMessage,
1428
1428
  title: (u = t.errorMessage) == null ? void 0 : u.title,
1429
- message: (k = t.errorMessage) == null ? void 0 : k.message
1429
+ message: (C = t.errorMessage) == null ? void 0 : C.message
1430
1430
  };
1431
1431
  }), i = N(() => t.cacheIdentifier || t.preferencesStorageKey), o = (u) => u.hasData || !!t.query, c = N(() => {
1432
1432
  const u = [];
1433
- return Object.keys(t.tableHeaders).forEach((k) => {
1434
- const q = t.tableHeaders[k];
1433
+ return Object.keys(t.tableHeaders).forEach((C) => {
1434
+ const q = t.tableHeaders[C];
1435
1435
  u.push({
1436
- label: q.label ?? k,
1437
- key: k,
1436
+ label: q.label ?? C,
1437
+ key: C,
1438
1438
  sortable: q.sortable ?? !1
1439
1439
  });
1440
1440
  }), t.enableEntityActions && u.push({
@@ -1446,36 +1446,36 @@ const Jr = {
1446
1446
  "data-testid": u.name,
1447
1447
  ...t.rowAttributes(u)
1448
1448
  }), b = v({}), y = (u) => {
1449
- var k;
1450
- return (k = b.value) == null ? void 0 : k.$el.querySelector(`[data-rowid="${u.id}"]`);
1449
+ var C;
1450
+ return (C = b.value) == null ? void 0 : C.$el.querySelector(`[data-rowid="${u.id}"]`);
1451
1451
  }, A = (u) => {
1452
- const k = {
1452
+ const C = {
1453
1453
  "data-testid": u.headerKey,
1454
1454
  ...t.cellAttributes(u)
1455
1455
  };
1456
- return u.colIndex === 0 && (k.style = {
1456
+ return u.colIndex === 0 && (C.style = {
1457
1457
  maxWidth: "250px",
1458
1458
  overflowX: "hidden",
1459
1459
  textOverflow: "ellipsis"
1460
- }), k;
1460
+ }), C;
1461
1461
  }, _ = () => {
1462
- a("empty-state-cta-clicked"), U();
1463
- }, U = () => {
1462
+ a("empty-state-cta-clicked"), R();
1463
+ }, R = () => {
1464
1464
  a("clear-search-input");
1465
- }, f = N(() => t.disableRowClick ? void 0 : (u, k) => {
1466
- a("click:row", k);
1465
+ }, f = N(() => t.disableRowClick ? void 0 : (u, C) => {
1466
+ a("click:row", C);
1467
1467
  }), T = (u) => {
1468
1468
  a("sort", u);
1469
- }, { setTablePreferences: F, getTablePreferences: Z } = at(), ae = N(() => {
1469
+ }, { setTablePreferences: P, getTablePreferences: Z } = at(), ae = N(() => {
1470
1470
  const u = Z(t.preferencesStorageKey);
1471
1471
  return {
1472
1472
  ...t.initialFetcherParams,
1473
1473
  ...u
1474
1474
  };
1475
1475
  }), w = (u) => {
1476
- t.preferencesStorageKey && F(t.preferencesStorageKey, u);
1476
+ t.preferencesStorageKey && P(t.preferencesStorageKey, u);
1477
1477
  };
1478
- return (u, k) => {
1478
+ return (u, C) => {
1479
1479
  const q = L("KIcon"), E = L("KButton"), K = L("KDropdown"), z = L("KTable"), I = L("KCard");
1480
1480
  return j(), J(I, {
1481
1481
  class: "kong-ui-entity-base-table",
@@ -1511,7 +1511,7 @@ const Jr = {
1511
1511
  "search-input": e.query,
1512
1512
  onKtableEmptyStateCtaClicked: _,
1513
1513
  "onRow:click": f.value,
1514
- onSort: k[0] || (k[0] = (O) => T(O)),
1514
+ onSort: C[0] || (C[0] = (O) => T(O)),
1515
1515
  "onUpdate:tablePreferences": w
1516
1516
  }, Te({
1517
1517
  toolbar: s(({ state: O }) => [
@@ -1524,7 +1524,7 @@ const Jr = {
1524
1524
  [Ie, o(O)]
1525
1525
  ])
1526
1526
  ]),
1527
- actions: s(({ row: O, rowKey: R, rowValue: W }) => [
1527
+ actions: s(({ row: O, rowKey: B, rowValue: W }) => [
1528
1528
  ee("div", {
1529
1529
  class: "actions-container",
1530
1530
  "data-testid": O.name
@@ -1536,7 +1536,7 @@ const Jr = {
1536
1536
  items: s(() => [
1537
1537
  Y(u.$slots, "actions", {
1538
1538
  row: O,
1539
- rowKey: R,
1539
+ rowKey: B,
1540
1540
  rowValue: W
1541
1541
  }, void 0, !0)
1542
1542
  ]),
@@ -1562,20 +1562,20 @@ const Jr = {
1562
1562
  ]),
1563
1563
  _: 2
1564
1564
  }, [
1565
- xe(e.tableHeaders, (O, R) => ({
1566
- name: R,
1567
- fn: s(({ row: W, rowKey: d, rowValue: C }) => [
1565
+ xe(e.tableHeaders, (O, B) => ({
1566
+ name: B,
1567
+ fn: s(({ row: W, rowKey: d, rowValue: k }) => [
1568
1568
  g(Hr, {
1569
- "key-name": String(R),
1569
+ "key-name": String(B),
1570
1570
  "row-el": y(W)
1571
1571
  }, {
1572
1572
  default: s(() => [
1573
- Y(u.$slots, R, {
1573
+ Y(u.$slots, B, {
1574
1574
  row: W,
1575
1575
  rowKey: d,
1576
- rowValue: C
1576
+ rowValue: k
1577
1577
  }, () => [
1578
- D(x(C), 1)
1578
+ U(x(k), 1)
1579
1579
  ], !0)
1580
1580
  ]),
1581
1581
  _: 2
@@ -1655,7 +1655,7 @@ const Jr = {
1655
1655
  e.error ? (j(), G("div", Xr, [
1656
1656
  g(b, { appearance: "danger" }, {
1657
1657
  alertMessage: s(() => [
1658
- D(x(e.error), 1)
1658
+ U(x(e.error), 1)
1659
1659
  ]),
1660
1660
  _: 1
1661
1661
  })
@@ -1666,7 +1666,7 @@ const Jr = {
1666
1666
  tag: "p"
1667
1667
  }, Te({
1668
1668
  entityType: s(() => [
1669
- D(x(a.entityType), 1)
1669
+ U(x(a.entityType), 1)
1670
1670
  ]),
1671
1671
  _: 2
1672
1672
  }, [
@@ -1806,57 +1806,57 @@ const Jr = {
1806
1806
  return a.config.app === "konnect" ? d = d.replace(/{controlPlaneId}/gi, a.config.controlPlaneId || "").replace(/{consumerId}/gi, a.config.consumerId || "").replace(/{plugin}/gi, a.config.plugin || "") : a.config.app === "kongManager" && (d = d.replace(/\/{workspace}/gi, a.config.workspace ? `/${a.config.workspace}` : "").replace(/{consumerId}/gi, a.config.consumerId || "").replace(/{plugin}/gi, a.config.plugin || "")), d;
1807
1807
  }), { fetcher: y, fetcherState: A } = ia(a.config, b), _ = () => {
1808
1808
  o.value++;
1809
- }, U = v(null), f = (d, C, B) => {
1810
- const P = C ? d[C] : JSON.stringify(d);
1811
- if (!B(P)) {
1812
- Z(d, C);
1809
+ }, R = v(null), f = (d, k, M) => {
1810
+ const F = k ? d[k] : JSON.stringify(d);
1811
+ if (!M(F)) {
1812
+ Z(d, k);
1813
1813
  return;
1814
1814
  }
1815
- F(d, C);
1816
- }, T = (d, C, B) => {
1817
- const { type: P } = d;
1818
- P === "success" ? F(C, B) : Z(C, B);
1819
- }, F = (d, C) => {
1815
+ P(d, k);
1816
+ }, T = (d, k, M) => {
1817
+ const { type: F } = d;
1818
+ F === "success" ? P(k, M) : Z(k, M);
1819
+ }, P = (d, k) => {
1820
1820
  t("copy:success", {
1821
1821
  entity: d,
1822
- field: C,
1823
- message: C ? n("credentials.copy.success", { val: d[C] }) : n("credentials.copy.success_brief")
1822
+ field: k,
1823
+ message: k && !["password", "key", "client_secret", "secret"].includes(k) ? n("credentials.copy.success", { val: d[k] }) : n("credentials.copy.success_brief")
1824
1824
  });
1825
- }, Z = (d, C) => {
1825
+ }, Z = (d, k) => {
1826
1826
  t("copy:error", {
1827
1827
  entity: d,
1828
- field: C,
1828
+ field: k,
1829
1829
  message: n("credentials.error.copy")
1830
1830
  });
1831
1831
  }, ae = (d) => ({
1832
1832
  label: n("credentials.actions.edit"),
1833
1833
  to: a.config.getEditRoute(d)
1834
- }), w = v(void 0), u = v(!1), k = v(!1), q = v(""), E = na(a.config, b.value), K = N(() => je[a.config.plugin]), z = (d) => {
1834
+ }), w = v(void 0), u = v(!1), C = v(!1), q = v(""), E = na(a.config, b.value), K = N(() => je[a.config.plugin]), z = (d) => {
1835
1835
  w.value = d, u.value = !0;
1836
1836
  }, I = () => {
1837
1837
  u.value = !1;
1838
1838
  }, O = async () => {
1839
- var d, C, B;
1839
+ var d, k, M;
1840
1840
  if ((d = w.value) != null && d.id) {
1841
- k.value = !0;
1841
+ C.value = !0;
1842
1842
  try {
1843
- await i.delete(E(w.value.id)), k.value = !1, u.value = !1, o.value++, t("delete:success", w.value);
1844
- } catch (P) {
1845
- q.value = ((B = (C = P.response) == null ? void 0 : C.data) == null ? void 0 : B.message) || P.message || n("credentials.error.delete"), t("error", P);
1843
+ await i.delete(E(w.value.id)), C.value = !1, u.value = !1, o.value++, t("delete:success", w.value);
1844
+ } catch (F) {
1845
+ q.value = ((M = (k = F.response) == null ? void 0 : k.data) == null ? void 0 : M.message) || F.message || n("credentials.error.delete"), t("error", F);
1846
1846
  } finally {
1847
- k.value = !1;
1847
+ C.value = !1;
1848
1848
  }
1849
1849
  }
1850
- }, R = v(!0);
1850
+ }, B = v(!0);
1851
1851
  oe(A, (d) => {
1852
- var C, B, P, le;
1853
- if (Array.isArray((C = d == null ? void 0 : d.response) == null ? void 0 : C.data) && (R.value = d.response.data.length > 0), d.status === Q.Error) {
1854
- U.value = {
1852
+ var k, M, F, le;
1853
+ if (Array.isArray((k = d == null ? void 0 : d.response) == null ? void 0 : k.data) && (B.value = d.response.data.length > 0), d.status === Q.Error) {
1854
+ R.value = {
1855
1855
  title: n("credentials.error.general")
1856
- }, (le = (P = (B = d.error) == null ? void 0 : B.response) == null ? void 0 : P.data) != null && le.message && (U.value.message = d.error.response.data.message), t("error", d.error);
1856
+ }, (le = (F = (M = d.error) == null ? void 0 : M.response) == null ? void 0 : F.data) != null && le.message && (R.value.message = d.error.response.data.message), t("error", d.error);
1857
1857
  return;
1858
1858
  }
1859
- U.value = null;
1859
+ R.value = null;
1860
1860
  });
1861
1861
  const W = v({
1862
1862
  ctaPath: a.config.createRoute,
@@ -1866,8 +1866,8 @@ const Jr = {
1866
1866
  });
1867
1867
  return Je(async () => {
1868
1868
  await a.canCreate() && (W.value.title = n(`credentials.list.empty_state.${a.config.plugin}.title`), W.value.ctaText = n(`credentials.list.empty_state.${a.config.plugin}.cta`));
1869
- }), (d, C) => {
1870
- const B = L("KButton"), P = L("CopyUuid"), le = L("KBadge"), Re = L("KTruncate"), H = L("KDropdownItem"), te = L("KClipboardProvider");
1869
+ }), (d, k) => {
1870
+ const M = L("KButton"), F = L("CopyUuid"), le = L("KBadge"), Re = L("KTruncate"), H = L("KDropdownItem"), te = L("KClipboardProvider");
1871
1871
  return j(), G("div", la, [
1872
1872
  g(m(Qr), {
1873
1873
  "cache-identifier": e.cacheIdentifier,
@@ -1876,7 +1876,7 @@ const Jr = {
1876
1876
  "disable-sorting": "",
1877
1877
  "empty-state-options": W.value,
1878
1878
  "enable-entity-actions": "",
1879
- "error-message": U.value,
1879
+ "error-message": R.value,
1880
1880
  fetcher: m(y),
1881
1881
  "fetcher-cache-key": o.value,
1882
1882
  "pagination-type": "offset",
@@ -1894,18 +1894,18 @@ const Jr = {
1894
1894
  "auth-function": () => e.canCreate()
1895
1895
  }, {
1896
1896
  default: s(() => [
1897
- Ne(g(B, {
1897
+ Ne(g(M, {
1898
1898
  appearance: "primary",
1899
1899
  "data-testid": "toolbar-add-credential",
1900
1900
  icon: "plus",
1901
1901
  to: e.config.createRoute
1902
1902
  }, {
1903
1903
  default: s(() => [
1904
- D(x(m(n)(`credentials.list.toolbar_actions.${e.config.plugin}.new`)), 1)
1904
+ U(x(m(n)(`credentials.list.toolbar_actions.${e.config.plugin}.new`)), 1)
1905
1905
  ]),
1906
1906
  _: 1
1907
1907
  }, 8, ["to"]), [
1908
- [Ie, R.value]
1908
+ [Ie, B.value]
1909
1909
  ])
1910
1910
  ]),
1911
1911
  _: 1
@@ -1924,46 +1924,46 @@ const Jr = {
1924
1924
  ee("span", null, x(h ?? "-"), 1)
1925
1925
  ]),
1926
1926
  password: s(({ row: h, rowValue: S }) => [
1927
- g(P, {
1927
+ g(F, {
1928
1928
  format: "redacted",
1929
- notify: (M) => T(M, h, "password"),
1929
+ notify: (D) => T(D, h, "password"),
1930
1930
  uuid: S
1931
1931
  }, null, 8, ["notify", "uuid"])
1932
1932
  ]),
1933
1933
  key: s(({ row: h, rowValue: S }) => [
1934
- g(P, {
1934
+ g(F, {
1935
1935
  format: "redacted",
1936
- notify: (M) => T(M, h, "key"),
1936
+ notify: (D) => T(D, h, "key"),
1937
1937
  uuid: S
1938
1938
  }, null, 8, ["notify", "uuid"])
1939
1939
  ]),
1940
1940
  client_secret: s(({ row: h, rowValue: S }) => [
1941
- g(P, {
1941
+ g(F, {
1942
1942
  format: "redacted",
1943
- notify: (M) => T(M, h, "client_secret"),
1943
+ notify: (D) => T(D, h, "client_secret"),
1944
1944
  uuid: S
1945
1945
  }, null, 8, ["notify", "uuid"])
1946
1946
  ]),
1947
1947
  secret: s(({ row: h, rowValue: S }) => [
1948
- g(P, {
1948
+ g(F, {
1949
1949
  format: "redacted",
1950
- notify: (M) => T(M, h, "secret"),
1950
+ notify: (D) => T(D, h, "secret"),
1951
1951
  uuid: S
1952
1952
  }, null, 8, ["notify", "uuid"])
1953
1953
  ]),
1954
1954
  created_at: s(({ rowValue: h }) => [
1955
- D(x(m(l)(h)), 1)
1955
+ U(x(m(l)(h)), 1)
1956
1956
  ]),
1957
1957
  tags: s(({ rowValue: h }) => [
1958
1958
  (h == null ? void 0 : h.length) > 0 ? (j(), J(Re, { key: 0 }, {
1959
1959
  default: s(() => [
1960
1960
  (j(!0), G(He, null, xe(h, (S) => (j(), J(le, {
1961
1961
  key: S,
1962
- onClick: C[0] || (C[0] = Ye(() => {
1962
+ onClick: k[0] || (k[0] = Ye(() => {
1963
1963
  }, ["stop"]))
1964
1964
  }, {
1965
1965
  default: s(() => [
1966
- D(x(S), 1)
1966
+ U(x(S), 1)
1967
1967
  ]),
1968
1968
  _: 2
1969
1969
  }, 1024))), 128))
@@ -1976,10 +1976,10 @@ const Jr = {
1976
1976
  default: s(({ copyToClipboard: S }) => [
1977
1977
  g(H, {
1978
1978
  "data-testid": "action-entity-copy-id",
1979
- onClick: (M) => f(h, "id", S)
1979
+ onClick: (D) => f(h, "id", S)
1980
1980
  }, {
1981
1981
  default: s(() => [
1982
- D(x(m(n)("credentials.actions.copy_id")), 1)
1982
+ U(x(m(n)("credentials.actions.copy_id")), 1)
1983
1983
  ]),
1984
1984
  _: 2
1985
1985
  }, 1032, ["onClick"])
@@ -1990,10 +1990,10 @@ const Jr = {
1990
1990
  default: s(({ copyToClipboard: S }) => [
1991
1991
  g(H, {
1992
1992
  "data-testid": "action-entity-copy-credential",
1993
- onClick: (M) => f(h, "password", S)
1993
+ onClick: (D) => f(h, "password", S)
1994
1994
  }, {
1995
1995
  default: s(() => [
1996
- D(x(m(n)("credentials.actions.copy_credential")), 1)
1996
+ U(x(m(n)("credentials.actions.copy_credential")), 1)
1997
1997
  ]),
1998
1998
  _: 2
1999
1999
  }, 1032, ["onClick"])
@@ -2004,10 +2004,10 @@ const Jr = {
2004
2004
  default: s(({ copyToClipboard: S }) => [
2005
2005
  g(H, {
2006
2006
  "data-testid": "action-entity-copy-key",
2007
- onClick: (M) => f(h, "key", S)
2007
+ onClick: (D) => f(h, "key", S)
2008
2008
  }, {
2009
2009
  default: s(() => [
2010
- D(x(m(n)("credentials.actions.copy_key")), 1)
2010
+ U(x(m(n)("credentials.actions.copy_key")), 1)
2011
2011
  ]),
2012
2012
  _: 2
2013
2013
  }, 1032, ["onClick"])
@@ -2018,10 +2018,10 @@ const Jr = {
2018
2018
  default: s(({ copyToClipboard: S }) => [
2019
2019
  g(H, {
2020
2020
  "data-testid": "action-entity-copy-secret",
2021
- onClick: (M) => f(h, "client_secret", S)
2021
+ onClick: (D) => f(h, "client_secret", S)
2022
2022
  }, {
2023
2023
  default: s(() => [
2024
- D(x(m(n)("credentials.actions.copy_secret")), 1)
2024
+ U(x(m(n)("credentials.actions.copy_secret")), 1)
2025
2025
  ]),
2026
2026
  _: 2
2027
2027
  }, 1032, ["onClick"])
@@ -2032,10 +2032,10 @@ const Jr = {
2032
2032
  default: s(({ copyToClipboard: S }) => [
2033
2033
  g(H, {
2034
2034
  "data-testid": "action-entity-copy-secret",
2035
- onClick: (M) => f(h, "secret", S)
2035
+ onClick: (D) => f(h, "secret", S)
2036
2036
  }, {
2037
2037
  default: s(() => [
2038
- D(x(m(n)("credentials.actions.copy_secret")), 1)
2038
+ U(x(m(n)("credentials.actions.copy_secret")), 1)
2039
2039
  ]),
2040
2040
  _: 2
2041
2041
  }, 1032, ["onClick"])
@@ -2046,10 +2046,10 @@ const Jr = {
2046
2046
  default: s(({ copyToClipboard: S }) => [
2047
2047
  g(H, {
2048
2048
  "data-testid": "action-entity-copy-json",
2049
- onClick: (M) => f(h, void 0, S)
2049
+ onClick: (D) => f(h, void 0, S)
2050
2050
  }, {
2051
2051
  default: s(() => [
2052
- D(x(m(n)("credentials.actions.copy_json")), 1)
2052
+ U(x(m(n)("credentials.actions.copy_json")), 1)
2053
2053
  ]),
2054
2054
  _: 2
2055
2055
  }, 1032, ["onClick"])
@@ -2079,7 +2079,7 @@ const Jr = {
2079
2079
  onClick: (S) => z(h)
2080
2080
  }, {
2081
2081
  default: s(() => [
2082
- D(x(m(n)("credentials.actions.delete")), 1)
2082
+ U(x(m(n)("credentials.actions.delete")), 1)
2083
2083
  ]),
2084
2084
  _: 2
2085
2085
  }, 1032, ["onClick"])
@@ -2090,7 +2090,7 @@ const Jr = {
2090
2090
  _: 1
2091
2091
  }, 8, ["cache-identifier", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "table-headers", "use-action-outside"]),
2092
2092
  g(m(ra), {
2093
- "action-pending": k.value,
2093
+ "action-pending": C.value,
2094
2094
  description: m(n)("credentials.delete.description"),
2095
2095
  "entity-type": K.value,
2096
2096
  error: q.value,
@@ -2107,7 +2107,7 @@ const Jr = {
2107
2107
  for (const [a, n] of r)
2108
2108
  t[a] = n;
2109
2109
  return t;
2110
- }, _a = /* @__PURE__ */ ca(sa, [["__scopeId", "data-v-6e469a8e"]]);
2110
+ }, _a = /* @__PURE__ */ ca(sa, [["__scopeId", "data-v-7dc7625b"]]);
2111
2111
  export {
2112
2112
  _a as ConsumerCredentialList
2113
2113
  };
@@ -1,5 +1,5 @@
1
- (function(V,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("@kong-ui-public/i18n"),require("axios"),require("@kong/kongponents"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","@kong-ui-public/i18n","axios","@kong/kongponents","vue-router"],t):(V=typeof globalThis<"u"?globalThis:V||self,t(V["kong-ui-public-entities-consumer-credentials"]={},V.Vue,V["kong-ui-public-i18n"],V.axios))})(this,function(V,t,W,ae){"use strict";const _e={credentials:{title:"Consumer Credentials",list:{toolbar_actions:{acls:{new:"New ACL Credential"},"basic-auth":{new:"New Basic Auth Credential"},"key-auth":{new:"New Key Auth Credential"},"key-auth-enc":{new:"New Key Auth Encrypted Credential"},oauth2:{new:"New OAuth 2.0 Credential"},"hmac-auth":{new:"New HMAC Credential"},jwt:{new:"New JWT Credential"}},table_headers:{acls:{group:"Group",created_at:"Created At",tags:"Tags"},"basic-auth":{password:"Credential",username:"Username",created_at:"Created at",tags:"Tags"},"key-auth":{key:"Key",created_at:"Created at",tags:"Tags"},"key-auth-enc":{key:"Key",created_at:"Created at",tags:"Tags"},oauth2:{name:"Name",client_id:"Client ID",client_secret:"Client secret",created_at:"Created at",tags:"Tags"},"hmac-auth":{username:"Username",secret:"Secret",created_at:"Created at",tags:"Tags"},jwt:{key:"Key",algorithm:"Algorithm",created_at:"Created at",tags:"Tags"}},empty_state:{acls:{title:"Configure a New ACL Credential",cta:"New ACL Credential"},"basic-auth":{title:"Configure a New Basic Auth Credential",cta:"New Basic Auth Credential"},"key-auth":{title:"Configure a New Key Auth Credential",cta:"New Key Auth Credential"},"key-auth-enc":{title:"Configure a New Key Auth Encrypted Credential",cta:"New Key Auth Encrypted Credential"},oauth2:{title:"Configure a New OAuth 2.0 Credential",cta:"New OAuth 2.0 Credential"},"hmac-auth":{title:"Configure a New HMAC Credential",cta:"New HMAC Credential"},jwt:{title:"Configure a New JWT Credential",cta:"New JWT Credential"}}},actions:{copy_id:"Copy ID",copy_credential:"Copy Credential",copy_key:"Copy Key",copy_secret:"Copy Secret",copy_json:"Copy JSON",edit:"Edit",delete:"Delete"},delete:{acls:{title:"Delete an ACL Credential"},"basic-auth":{title:"Delete a Basic Auth Credential"},"key-auth":{title:"Delete a Key Auth Credential"},"key-auth-enc":{title:"Delete a Key Auth Encrypted Credential"},oauth2:{title:"Delete an OAuth 2.0 Credential"},"hmac-auth":{title:"Delete an HMAC Credential"},jwt:{title:"Delete a JWT Credential"},description:"This action cannot be reversed."},error:{general:"Credentials could not be retrieved",delete:"The credential could not be deleted at this time.",copy:"Failed to copy to clipboard"},copy:{success:"Copied {val} to clipboard",success_brief:"Successfully copied to clipboard"}}};function xe(){const e=W.createI18n("en-us",_e);return{i18n:e,i18nT:W.i18nTComponent(e)}}const Ne={useI18n:xe},Se={list:{konnect:"/api/runtime_groups/{controlPlaneId}/consumers/{consumerId}/{plugin}",kongManager:"/{workspace}/consumers/{consumerId}/{plugin}"}};var ie=(e=>(e.GatewayService="service",e.Route="route",e.Consumer="consumer",e.ConsumerGroup="consumer group",e.Plugin="plugin",e.Upstream="upstream",e.Certificate="certificate",e.CACertificate="ca certificate",e.SNI="SNI",e.Key="key",e.KeySet="key set",e.Vault="vault",e.Application="application",e.Developer="developer",e.acls="ACL Credential",e["basic-auth"]="Basic Auth Credential",e["key-auth"]="Key Auth Credential",e["key-auth-enc"]="Key Auth Encrypted Credential",e.oauth2="OAuth 2.0 Credential",e["hmac-auth"]="HMAC Credential",e.jwt="JWT Credential",e.Target="target",e.Policy="policy",e))(ie||{}),F=(e=>(e[e.Loading=0]="Loading",e[e.Idle=1]="Idle",e[e.NoResults=2]="NoResults",e[e.Error=3]="Error",e))(F||{});function Te(){return{getAxiosInstance:(e={})=>{try{const n=t.inject("get-axios-instance",void 0);return typeof n=="function"?n(e):ae.create({withCredentials:!0,timeout:3e4,...e})}catch(n){return console.warn("getAxiosInstance:",n.message||n),ae.create({withCredentials:!0,timeout:3e4,...e})}},getTraceIdFromError:e=>{var n;return((n=e==null?void 0:e.response)==null?void 0:n.headers["x-datadog-trace-id"])||""}}}function Ae(){return{debounce:(e,n)=>{let r;return(...a)=>{clearTimeout(r),r=window==null?void 0:window.setTimeout(()=>{e(...a)},n)}}}}const Y="khcp-user-table-preferences",Ee={pageSize:30,sortColumnKey:void 0,sortColumnOrder:void 0};function Ie(){const e=r=>{if(typeof r=="string")try{return JSON.parse(r)}catch(a){console.error("useTablePreferences(tryParseJson)",a);return}},n=()=>{const r=e(localStorage.getItem(Y));return!r||!Object.keys(r).length?new Map:new Map(Object.entries(r))};return{setTablePreferences:(r,a)=>{try{const i=n();i.set(r,a),localStorage.setItem(Y,JSON.stringify(Object.fromEntries(i.entries())))}catch(i){console.error("useTablePreferences(setTablePreferences)",i)}},getTablePreferences:r=>{const a=n();return(a==null?void 0:a.get(r))||void 0||Ee},deleteAllTablePreferences:()=>{localStorage.removeItem(Y)}}}function G(e={}){const{getAxiosInstance:n}=Te();return{axiosInstance:n(e)}}const Oe={actions:{copyId:"Copy ID",copied_id:'Copied "{id}" to the clipboard',copyToClipboard:"Copied successfully!",copyToClipboardFailed:"Failed to copy to the clipboard"}},je={message:"Are you sure you want to delete this {entityType}?",messageWithName:"Are you sure you want to delete this {entityType} {entityName}?"},ve={actions:{viewConfiguration:"View Configuration",save:"Save",cancel:"Cancel",back:"Back"},configuration:{title:"Configuration",message:"Export configurations for core Kong Gateway objects, like services, routes, and plugins, to either YAML or JSON. This allows for straightforward importing into APIOps tools like decK with YAML, or Insomnia and cURL with JSON.",yaml:"YAML",json:"JSON"},errors:{edit:"The entity could not be edited at this time."}},Be={emptyState:{noSearchResultsTitle:"No results found",noSearchResultsMessage:"Please adjust the criteria and try again.",noSearchResultsCtaText:"Clear"}},$e={title:"Configuration",actions:{copy:"Copy JSON"},sections:{advanced:"Advanced",plugin:"Plugin Specific Configuration"},commonFields:{id_label:"ID",name_label:"Name",enabled_label:"Enabled",enabled_tooltip:"Enabled is FTW",updated_at_label:"Last Updated",created_at_label:"Created",tags_label:"Tags",link:"Link"},statusBadge:{enabledLabel:"Enabled",disabledLabel:"Disabled"},copy:{tooltip:"Copy {label}",success:"Copied!"},errors:{load:"The entity configuration data could not be loaded at this time.",copy:"Failed to copy to clipboard"},general:{entryTitle:"Entry {index}",structuredFormat:"Structured"}},Ke={filterButtonText:"Filter",fieldLabel:"Filter by:",inputPlaceholder:"Enter a value",selectPlaceholder:"Select an item",applyButtonText:"Apply",clearButtonText:"Clear",clearAllButtonText:"Clear all filters"},Ve={errors:{fetch:"Could not fetch available items",invalid:"Please select a valid value"}},De={unexpected:"An unexpected error has occurred",dataKeyUndefined:'The data key "{dataKey}" does not exist in the response.'},Pe={enable:{title:"Enable {entityType}",message:"Are you sure you want to enable the {entityType} {entityName}?",confirmText:"Yes, enable"},disable:{title:"Disable {entityType}",message:"Are you sure you want to disable the {entityType} {entityName}?",confirmText:"Yes, disable"}},Le={global:Oe,deleteModal:je,baseForm:ve,baseTable:Be,baseConfigCard:$e,filter:Ke,debouncedFilter:Ve,errors:De,toggleModal:Pe};function Z(){const e=W.createI18n("en-us",Le);return{i18n:e,i18nT:W.i18nTComponent(e)}}function oe(){const e=(r,a)=>(a==null?void 0:a[r])??void 0,n=(r,a)=>{if(r.length!==a.length)return!1;const i=new Set([...r,...a]);for(const l of i){const o=r.filter(c=>c===l).length,s=a.filter(c=>c===l).length;if(o!==s)return!1}return!0};return{getPropValue:e,objectsAreEqual:(r,a,i)=>{if(i){if(Object.keys(r).length===Object.keys(a).length)for(const l in r)if(Array.isArray(r[l])&&Array.isArray(a[l])){if(n(r[l],a[l]))continue;return!1}else{if(r[l]===a[l])continue;return!1}else return!1;return!0}try{return JSON.stringify(r)===JSON.stringify(a)}catch{return!1}},sortAlpha:r=>(a,i)=>{let l=a[r]===void 0||a[r]===null?"":a[r],o=i[r]===void 0||i[r]===null?"":i[r];return Array.isArray(a[r])&&(l=a[r][0]),Array.isArray(i[r])&&(o=i[r][0]),l.localeCompare(o)},isValidUuid:r=>r?/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/.test(r):!1}}function Fe(e,n,r,a={fetchedItemsKey:"data",searchKeys:["id"]}){r||(r="100");const{axiosInstance:i}=G({headers:e.requestHeaders}),{i18n:{t:l}}=Z(),{debounce:o}=Ae(),s=o(async m=>{await J(m)},200),c=t.ref(!1),p=t.ref(""),g=t.ref(""),y=t.ref([]),_=t.ref([]),C=t.ref(void 0),v=t.unref(n);let f=`${e.apiBaseUrl}${v}`;e.app==="konnect"?f=f.replace(/{controlPlaneId}/gi,(e==null?void 0:e.controlPlaneId)||""):e.app==="kongManager"&&(f=f.replace(/\/{workspace}/gi,e!=null&&e.workspace?`/${e.workspace}`:""));const{isValidUuid:x}=oe(),O=async()=>{try{c.value=!0;const{data:m}=await i.get(`${f}?size=${r}`);m!=null&&m.next||(C.value=a.fetchedItemsKey in m?m[a.fetchedItemsKey]:[]),_.value=a.fetchedItemsKey in m?m[a.fetchedItemsKey]:[],y.value=_.value}catch{y.value=[],p.value=l("debouncedFilter.errors.fetch")}finally{c.value=!1}},U=t.ref(""),J=async m=>{var d,b,K;if(U.value!==m)if(U.value=m||"",C.value===void 0)try{if(c.value=!0,p.value="",g.value="",e.app==="konnect"){let S=f+"";m&&(S+=`/${m}`);const{data:E}=await i.get(`${S}?size=${r}`);a.fetchedItemsKey in E?y.value=E[a.fetchedItemsKey]:E!=null&&E.id?y.value=[E]:y.value=[]}else if(m){const S=[];x(m)&&a.searchKeys.includes("id")?S.push((async()=>{const{data:N}=await i.get(`${f}/${m}`);return[N[a.fetchedItemsKey]??N]})()):S.push(...a.searchKeys.filter(N=>N!=="id").map(async N=>{const{data:T}=await i.get(`${f}?${N}=${m}`);return T[a.fetchedItemsKey]}));const E=await Promise.all(S),D=new Set;y.value=[],(d=E==null?void 0:E.forEach)==null||d.call(E,N=>{var T;(T=N==null?void 0:N.forEach)==null||T.call(N,B=>{D.has(B.id)||(D.add(B.id),y.value.push(B))})})}else y.value=_.value}catch(S){((b=S==null?void 0:S.response)==null?void 0:b.status)===404?g.value=l("debouncedFilter.errors.invalid"):(y.value=[],p.value=l("debouncedFilter.errors.fetch"))}finally{c.value=!1}else c.value=!0,g.value="",m?(y.value=(K=C.value)==null?void 0:K.filter(S=>{var E;let D=!1;for(const N of a.searchKeys){const T=typeof S[N]=="string"?(E=S[N])==null?void 0:E.toLowerCase():S[N];T!=null&&T.includes(m.toLowerCase())&&(D=!0)}return D}),(!y.value||!y.value.length)&&(g.value=l("debouncedFilter.errors.invalid"))):y.value=C.value,c.value=!1};return{loading:c,error:p,validationError:g,results:y,allRecords:C,loadItems:O,debouncedQueryChange:s}}function Me(e,n){const r=t.unref(n),a=t.computed(()=>e.apiBaseUrl.startsWith("/")?new URL(`${window.location.origin}${r}`):new URL(r));return a.value.search="",i=>`${a.value.href}/${i}`}function Ue(){const{i18n:{t:e}}=Z();return{getMessageFromError:n=>{var r,a,i,l;if(!n)return e("errors.unexpected");if(((r=n==null?void 0:n.response)==null?void 0:r.status)===401)return console.warn("getMessageFromError: User auth token is expired or missing, returning empty message."),"";if((a=n==null?void 0:n.response)!=null&&a.data){if(n.response.data.detail)return n.response.data.detail;if((i=n.response.data.details)!=null&&i.length)return n.response.data.details.map(o=>{let s=e("errors.unexpected");return o.messages&&typeof o.messages=="object"&&o.messages.length&&(s=o.messages.join(", ")),o.field?`${o.field} - ${s}`:s}).join("; ");if(n.response.data.message){const{message:o}=n.response.data;return Array.isArray(o)?(l=o[0])!=null&&l.constraints?Object.values(o[0].constraints)[0]:o[0]:o}if(typeof n.response.data=="string")return n.response.data;if(typeof n.response.data=="object")return Object.keys(n.response.data).map(o=>`${o} ${n.response.data[o]}`).join(", ")}return n.message||e("errors.unexpected")}}}function Re(e){const n=window.location.origin,r=n.endsWith("/")?n:`${n}/`;try{const a=e.join("/"),i=`${r}${a}`,l=e.some(o=>o.trim()==="");if(/^(https:\/\/(www\.)?([a-zA-Z0-9-]+\.){1,}[a-zA-Z]{2,}(:[0-9]+)?(\/[^\/]+)*)$|^(https|http):\/\/localhost(:[0-9]+)?(\/[^\/]+)*$/.test(i)&&!l&&new URL(i))return`${r}${a}`;throw new Error("Invalid url")}catch(a){return console.warn("Failed to build valid URL:",a),""}}function le(e,n){const r=t.ref(t.unref(e)),a=t.ref(t.unref(n)),i=t.computed(()=>!!(r.value.app==="konnect"||r.value.isExactMatch)),l=t.computed(()=>a.value.startsWith("/")?new URL(`${window.location.origin}${a.value}`):new URL(a.value));return o=>{const{page:s,pageSize:c,offset:p,sortColumnKey:g,sortColumnOrder:y,query:_}=o;try{let C=new URL(l.value.href);return i.value&&_?(C.search="",C=r.value.app==="konnect"?new URL(`${C.href}?filter[name][contains]=${_}`):new URL(`${C.href}/${_}/`)):(i.value||new URLSearchParams(_).forEach((v,f)=>{C.searchParams.append(f,v)}),g&&C.searchParams.append("sort_by",g),y==="desc"&&C.searchParams.append("sort_desc","1"),C.searchParams.append("size",String(c))),p&&s!==1&&C.searchParams.append("offset",String(p)),C.href}catch(C){return console.error("RouteList(fetcher)",C),a.value}}}function qe(e,n,r="data"){const a=t.unref(n),{axiosInstance:i}=G({headers:e.requestHeaders}),l=le(e,a),o=t.ref({status:F.Idle});return{fetcher:async s=>{try{o.value={status:F.Loading};let c=l(s);c.includes("filter[name]")&&(c=`${c}&page[size]=${s.pageSize}&page[number]=${s.page}`);const{data:p}=await i.get(c),g=r&&r.replace(/[^\w-_]/gi,"");let y;p[g]&&Array.isArray(p[g])?y=p[g]:Array.isArray(p)?y=p:y=Object.keys(p).length?[p]:[];const _={data:y,total:y.length,...p.offset?{pagination:{offset:p.offset}}:null};return o.value={status:F.Idle,response:_},_}catch(c){const p={data:[],total:0};return s.query&&c.response.status===404?(o.value={status:F.NoResults,response:p,error:c},p):(o.value={status:F.Error,response:p,error:c},p)}},fetcherState:o}}function ze(){const e=(r,a="_")=>r?r.split(a).map(i=>i.toLowerCase()==="id"?i.toUpperCase():i.charAt(0).toUpperCase()+i.substring(1)).join(" "):"",n=/(?:^|[\s-:'"])\w/g;return{capitalize:r=>r?r.replace(n,a=>a.toUpperCase()):"",convertKeyToTitle:e}}const se=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,ce=e=>{if(typeof e!="string")throw new TypeError("Invalid argument expected string");const n=e.match(se);if(!n)throw new Error(`Invalid argument not valid semver ('${e}' received)`);return n.shift(),n},de=e=>e==="*"||e==="x"||e==="X",ue=e=>{const n=parseInt(e,10);return isNaN(n)?e:n},Je=(e,n)=>typeof e!=typeof n?[String(e),String(n)]:[e,n],We=(e,n)=>{if(de(e)||de(n))return 0;const[r,a]=Je(ue(e),ue(n));return r>a?1:r<a?-1:0},pe=(e,n)=>{for(let r=0;r<Math.max(e.length,n.length);r++){const a=We(e[r]||"0",n[r]||"0");if(a!==0)return a}return 0},He=(e,n)=>{const r=ce(e),a=ce(n),i=r.pop(),l=a.pop(),o=pe(r,a);return o!==0?o:i&&l?pe(i.split("."),l.split(".")):i||l?i?-1:1:0},fe=(e,n,r)=>{Ye(r);const a=He(e,n);return ye[r].includes(a)},ye={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},he=Object.keys(ye),Ye=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(he.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${he.join("|")}`)},Ge=e=>typeof e=="string"&&/^[v\d]/.test(e)&&se.test(e);function Ze(e){const{gatewayInfo:n,supportedRange:r}=e;if(!n)return!0;const{edition:a,version:i}=n;if(!Ge(i))return console.error("Invalid version"),!1;const l=r[a];if(!l)return!1;const[o,s]=l;return!(o&&fe(i,o,"<")||s&&fe(i,s,">"))}function Qe(e){const n=t.ref(0),r=t.ref(0),a=t.ref(!1);return t.watch(e,i=>{i&&!a.value&&(n.value=i.offsetWidth,r.value=i.scrollWidth,a.value=!0)}),{isTruncated:t.computed(()=>n.value<r.value)}}const Q={useAxios:G,useDebouncedFilter:Fe,useDeleteUrlBuilder:Me,useErrors:Ue,useExternalLinkCreator:Re,useFetcher:qe,useFetchUrlBuilder:le,useHelpers:oe,useStringHelpers:ze,useI18n:Z,useGatewayFeatureSupported:Ze,useTruncationDetector:Qe},X=(e,n)=>{const r=e.__vccOpts||e;for(const[a,i]of n)r[a]=i;return r},Xe="#3a3f51";/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function ge(e){return typeof e>"u"||e===null}function et(e){return typeof e=="object"&&e!==null}function tt(e){return Array.isArray(e)?e:ge(e)?[]:[e]}function rt(e,n){var r,a,i,l;if(n)for(l=Object.keys(n),r=0,a=l.length;r<a;r+=1)i=l[r],e[i]=n[i];return e}function nt(e,n){var r="",a;for(a=0;a<n;a+=1)r+=e;return r}function at(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}var it=ge,ot=et,lt=tt,st=nt,ct=at,dt=rt,ee={isNothing:it,isObject:ot,toArray:lt,repeat:st,isNegativeZero:ct,extend:dt};function me(e,n){var r="",a=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(r+='in "'+e.mark.name+'" '),r+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!n&&e.mark.snippet&&(r+=`
1
+ (function(V,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("@kong-ui-public/i18n"),require("axios"),require("@kong/kongponents"),require("vue-router")):typeof define=="function"&&define.amd?define(["exports","vue","@kong-ui-public/i18n","axios","@kong/kongponents","vue-router"],t):(V=typeof globalThis<"u"?globalThis:V||self,t(V["kong-ui-public-entities-consumer-credentials"]={},V.Vue,V["kong-ui-public-i18n"],V.axios))})(this,function(V,t,W,ae){"use strict";const _e={credentials:{title:"Consumer Credentials",list:{toolbar_actions:{acls:{new:"New ACL Credential"},"basic-auth":{new:"New Basic Auth Credential"},"key-auth":{new:"New Key Auth Credential"},"key-auth-enc":{new:"New Key Auth Encrypted Credential"},oauth2:{new:"New OAuth 2.0 Credential"},"hmac-auth":{new:"New HMAC Credential"},jwt:{new:"New JWT Credential"}},table_headers:{acls:{group:"Group",created_at:"Created At",tags:"Tags"},"basic-auth":{password:"Credential",username:"Username",created_at:"Created at",tags:"Tags"},"key-auth":{key:"Key",created_at:"Created at",tags:"Tags"},"key-auth-enc":{key:"Key",created_at:"Created at",tags:"Tags"},oauth2:{name:"Name",client_id:"Client ID",client_secret:"Client secret",created_at:"Created at",tags:"Tags"},"hmac-auth":{username:"Username",secret:"Secret",created_at:"Created at",tags:"Tags"},jwt:{key:"Key",algorithm:"Algorithm",created_at:"Created at",tags:"Tags"}},empty_state:{acls:{title:"Configure a New ACL Credential",cta:"New ACL Credential"},"basic-auth":{title:"Configure a New Basic Auth Credential",cta:"New Basic Auth Credential"},"key-auth":{title:"Configure a New Key Auth Credential",cta:"New Key Auth Credential"},"key-auth-enc":{title:"Configure a New Key Auth Encrypted Credential",cta:"New Key Auth Encrypted Credential"},oauth2:{title:"Configure a New OAuth 2.0 Credential",cta:"New OAuth 2.0 Credential"},"hmac-auth":{title:"Configure a New HMAC Credential",cta:"New HMAC Credential"},jwt:{title:"Configure a New JWT Credential",cta:"New JWT Credential"}}},actions:{copy_id:"Copy ID",copy_credential:"Copy Credential",copy_key:"Copy Key",copy_secret:"Copy Secret",copy_json:"Copy JSON",edit:"Edit",delete:"Delete"},delete:{acls:{title:"Delete an ACL Credential"},"basic-auth":{title:"Delete a Basic Auth Credential"},"key-auth":{title:"Delete a Key Auth Credential"},"key-auth-enc":{title:"Delete a Key Auth Encrypted Credential"},oauth2:{title:"Delete an OAuth 2.0 Credential"},"hmac-auth":{title:"Delete an HMAC Credential"},jwt:{title:"Delete a JWT Credential"},description:"This action cannot be reversed."},error:{general:"Credentials could not be retrieved",delete:"The credential could not be deleted at this time.",copy:"Failed to copy to clipboard"},copy:{success:"Copied {val} to clipboard",success_brief:"Successfully copied to clipboard"}}};function xe(){const e=W.createI18n("en-us",_e);return{i18n:e,i18nT:W.i18nTComponent(e)}}const Ne={useI18n:xe},Se={list:{konnect:"/api/runtime_groups/{controlPlaneId}/consumers/{consumerId}/{plugin}",kongManager:"/{workspace}/consumers/{consumerId}/{plugin}"}};var ie=(e=>(e.GatewayService="service",e.Route="route",e.Consumer="consumer",e.ConsumerGroup="consumer group",e.Plugin="plugin",e.Upstream="upstream",e.Certificate="certificate",e.CACertificate="ca certificate",e.SNI="SNI",e.Key="key",e.KeySet="key set",e.Vault="vault",e.Application="application",e.Developer="developer",e.acls="ACL Credential",e["basic-auth"]="Basic Auth Credential",e["key-auth"]="Key Auth Credential",e["key-auth-enc"]="Key Auth Encrypted Credential",e.oauth2="OAuth 2.0 Credential",e["hmac-auth"]="HMAC Credential",e.jwt="JWT Credential",e.Target="target",e.Policy="policy",e))(ie||{}),L=(e=>(e[e.Loading=0]="Loading",e[e.Idle=1]="Idle",e[e.NoResults=2]="NoResults",e[e.Error=3]="Error",e))(L||{});function Te(){return{getAxiosInstance:(e={})=>{try{const n=t.inject("get-axios-instance",void 0);return typeof n=="function"?n(e):ae.create({withCredentials:!0,timeout:3e4,...e})}catch(n){return console.warn("getAxiosInstance:",n.message||n),ae.create({withCredentials:!0,timeout:3e4,...e})}},getTraceIdFromError:e=>{var n;return((n=e==null?void 0:e.response)==null?void 0:n.headers["x-datadog-trace-id"])||""}}}function Ae(){return{debounce:(e,n)=>{let r;return(...a)=>{clearTimeout(r),r=window==null?void 0:window.setTimeout(()=>{e(...a)},n)}}}}const Y="khcp-user-table-preferences",Ee={pageSize:30,sortColumnKey:void 0,sortColumnOrder:void 0};function Ie(){const e=r=>{if(typeof r=="string")try{return JSON.parse(r)}catch(a){console.error("useTablePreferences(tryParseJson)",a);return}},n=()=>{const r=e(localStorage.getItem(Y));return!r||!Object.keys(r).length?new Map:new Map(Object.entries(r))};return{setTablePreferences:(r,a)=>{try{const i=n();i.set(r,a),localStorage.setItem(Y,JSON.stringify(Object.fromEntries(i.entries())))}catch(i){console.error("useTablePreferences(setTablePreferences)",i)}},getTablePreferences:r=>{const a=n();return(a==null?void 0:a.get(r))||void 0||Ee},deleteAllTablePreferences:()=>{localStorage.removeItem(Y)}}}function G(e={}){const{getAxiosInstance:n}=Te();return{axiosInstance:n(e)}}const Oe={actions:{copyId:"Copy ID",copied_id:'Copied "{id}" to the clipboard',copyToClipboard:"Copied successfully!",copyToClipboardFailed:"Failed to copy to the clipboard"}},je={message:"Are you sure you want to delete this {entityType}?",messageWithName:"Are you sure you want to delete this {entityType} {entityName}?"},ve={actions:{viewConfiguration:"View Configuration",save:"Save",cancel:"Cancel",back:"Back"},configuration:{title:"Configuration",message:"Export configurations for core Kong Gateway objects, like services, routes, and plugins, to either YAML or JSON. This allows for straightforward importing into APIOps tools like decK with YAML, or Insomnia and cURL with JSON.",yaml:"YAML",json:"JSON"},errors:{edit:"The entity could not be edited at this time."}},Be={emptyState:{noSearchResultsTitle:"No results found",noSearchResultsMessage:"Please adjust the criteria and try again.",noSearchResultsCtaText:"Clear"}},$e={title:"Configuration",actions:{copy:"Copy JSON"},sections:{advanced:"Advanced",plugin:"Plugin Specific Configuration"},commonFields:{id_label:"ID",name_label:"Name",enabled_label:"Enabled",enabled_tooltip:"Enabled is FTW",updated_at_label:"Last Updated",created_at_label:"Created",tags_label:"Tags",link:"Link"},statusBadge:{enabledLabel:"Enabled",disabledLabel:"Disabled"},copy:{tooltip:"Copy {label}",success:"Copied!"},errors:{load:"The entity configuration data could not be loaded at this time.",copy:"Failed to copy to clipboard"},general:{entryTitle:"Entry {index}",structuredFormat:"Structured"}},Ke={filterButtonText:"Filter",fieldLabel:"Filter by:",inputPlaceholder:"Enter a value",selectPlaceholder:"Select an item",applyButtonText:"Apply",clearButtonText:"Clear",clearAllButtonText:"Clear all filters"},Ve={errors:{fetch:"Could not fetch available items",invalid:"Please select a valid value"}},De={unexpected:"An unexpected error has occurred",dataKeyUndefined:'The data key "{dataKey}" does not exist in the response.'},Pe={enable:{title:"Enable {entityType}",message:"Are you sure you want to enable the {entityType} {entityName}?",confirmText:"Yes, enable"},disable:{title:"Disable {entityType}",message:"Are you sure you want to disable the {entityType} {entityName}?",confirmText:"Yes, disable"}},Fe={global:Oe,deleteModal:je,baseForm:ve,baseTable:Be,baseConfigCard:$e,filter:Ke,debouncedFilter:Ve,errors:De,toggleModal:Pe};function Z(){const e=W.createI18n("en-us",Fe);return{i18n:e,i18nT:W.i18nTComponent(e)}}function oe(){const e=(r,a)=>(a==null?void 0:a[r])??void 0,n=(r,a)=>{if(r.length!==a.length)return!1;const i=new Set([...r,...a]);for(const l of i){const o=r.filter(c=>c===l).length,s=a.filter(c=>c===l).length;if(o!==s)return!1}return!0};return{getPropValue:e,objectsAreEqual:(r,a,i)=>{if(i){if(Object.keys(r).length===Object.keys(a).length)for(const l in r)if(Array.isArray(r[l])&&Array.isArray(a[l])){if(n(r[l],a[l]))continue;return!1}else{if(r[l]===a[l])continue;return!1}else return!1;return!0}try{return JSON.stringify(r)===JSON.stringify(a)}catch{return!1}},sortAlpha:r=>(a,i)=>{let l=a[r]===void 0||a[r]===null?"":a[r],o=i[r]===void 0||i[r]===null?"":i[r];return Array.isArray(a[r])&&(l=a[r][0]),Array.isArray(i[r])&&(o=i[r][0]),l.localeCompare(o)},isValidUuid:r=>r?/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/.test(r):!1}}function Le(e,n,r,a={fetchedItemsKey:"data",searchKeys:["id"]}){r||(r="100");const{axiosInstance:i}=G({headers:e.requestHeaders}),{i18n:{t:l}}=Z(),{debounce:o}=Ae(),s=o(async m=>{await J(m)},200),c=t.ref(!1),p=t.ref(""),g=t.ref(""),y=t.ref([]),_=t.ref([]),C=t.ref(void 0),B=t.unref(n);let f=`${e.apiBaseUrl}${B}`;e.app==="konnect"?f=f.replace(/{controlPlaneId}/gi,(e==null?void 0:e.controlPlaneId)||""):e.app==="kongManager"&&(f=f.replace(/\/{workspace}/gi,e!=null&&e.workspace?`/${e.workspace}`:""));const{isValidUuid:x}=oe(),O=async()=>{try{c.value=!0;const{data:m}=await i.get(`${f}?size=${r}`);m!=null&&m.next||(C.value=a.fetchedItemsKey in m?m[a.fetchedItemsKey]:[]),_.value=a.fetchedItemsKey in m?m[a.fetchedItemsKey]:[],y.value=_.value}catch{y.value=[],p.value=l("debouncedFilter.errors.fetch")}finally{c.value=!1}},U=t.ref(""),J=async m=>{var d,w,K;if(U.value!==m)if(U.value=m||"",C.value===void 0)try{if(c.value=!0,p.value="",g.value="",e.app==="konnect"){let S=f+"";m&&(S+=`/${m}`);const{data:E}=await i.get(`${S}?size=${r}`);a.fetchedItemsKey in E?y.value=E[a.fetchedItemsKey]:E!=null&&E.id?y.value=[E]:y.value=[]}else if(m){const S=[];x(m)&&a.searchKeys.includes("id")?S.push((async()=>{const{data:N}=await i.get(`${f}/${m}`);return[N[a.fetchedItemsKey]??N]})()):S.push(...a.searchKeys.filter(N=>N!=="id").map(async N=>{const{data:T}=await i.get(`${f}?${N}=${m}`);return T[a.fetchedItemsKey]}));const E=await Promise.all(S),D=new Set;y.value=[],(d=E==null?void 0:E.forEach)==null||d.call(E,N=>{var T;(T=N==null?void 0:N.forEach)==null||T.call(N,$=>{D.has($.id)||(D.add($.id),y.value.push($))})})}else y.value=_.value}catch(S){((w=S==null?void 0:S.response)==null?void 0:w.status)===404?g.value=l("debouncedFilter.errors.invalid"):(y.value=[],p.value=l("debouncedFilter.errors.fetch"))}finally{c.value=!1}else c.value=!0,g.value="",m?(y.value=(K=C.value)==null?void 0:K.filter(S=>{var E;let D=!1;for(const N of a.searchKeys){const T=typeof S[N]=="string"?(E=S[N])==null?void 0:E.toLowerCase():S[N];T!=null&&T.includes(m.toLowerCase())&&(D=!0)}return D}),(!y.value||!y.value.length)&&(g.value=l("debouncedFilter.errors.invalid"))):y.value=C.value,c.value=!1};return{loading:c,error:p,validationError:g,results:y,allRecords:C,loadItems:O,debouncedQueryChange:s}}function Me(e,n){const r=t.unref(n),a=t.computed(()=>e.apiBaseUrl.startsWith("/")?new URL(`${window.location.origin}${r}`):new URL(r));return a.value.search="",i=>`${a.value.href}/${i}`}function Ue(){const{i18n:{t:e}}=Z();return{getMessageFromError:n=>{var r,a,i,l;if(!n)return e("errors.unexpected");if(((r=n==null?void 0:n.response)==null?void 0:r.status)===401)return console.warn("getMessageFromError: User auth token is expired or missing, returning empty message."),"";if((a=n==null?void 0:n.response)!=null&&a.data){if(n.response.data.detail)return n.response.data.detail;if((i=n.response.data.details)!=null&&i.length)return n.response.data.details.map(o=>{let s=e("errors.unexpected");return o.messages&&typeof o.messages=="object"&&o.messages.length&&(s=o.messages.join(", ")),o.field?`${o.field} - ${s}`:s}).join("; ");if(n.response.data.message){const{message:o}=n.response.data;return Array.isArray(o)?(l=o[0])!=null&&l.constraints?Object.values(o[0].constraints)[0]:o[0]:o}if(typeof n.response.data=="string")return n.response.data;if(typeof n.response.data=="object")return Object.keys(n.response.data).map(o=>`${o} ${n.response.data[o]}`).join(", ")}return n.message||e("errors.unexpected")}}}function Re(e){const n=window.location.origin,r=n.endsWith("/")?n:`${n}/`;try{const a=e.join("/"),i=`${r}${a}`,l=e.some(o=>o.trim()==="");if(/^(https:\/\/(www\.)?([a-zA-Z0-9-]+\.){1,}[a-zA-Z]{2,}(:[0-9]+)?(\/[^\/]+)*)$|^(https|http):\/\/localhost(:[0-9]+)?(\/[^\/]+)*$/.test(i)&&!l&&new URL(i))return`${r}${a}`;throw new Error("Invalid url")}catch(a){return console.warn("Failed to build valid URL:",a),""}}function le(e,n){const r=t.ref(t.unref(e)),a=t.ref(t.unref(n)),i=t.computed(()=>!!(r.value.app==="konnect"||r.value.isExactMatch)),l=t.computed(()=>a.value.startsWith("/")?new URL(`${window.location.origin}${a.value}`):new URL(a.value));return o=>{const{page:s,pageSize:c,offset:p,sortColumnKey:g,sortColumnOrder:y,query:_}=o;try{let C=new URL(l.value.href);return i.value&&_?(C.search="",C=r.value.app==="konnect"?new URL(`${C.href}?filter[name][contains]=${_}`):new URL(`${C.href}/${_}/`)):(i.value||new URLSearchParams(_).forEach((B,f)=>{C.searchParams.append(f,B)}),g&&C.searchParams.append("sort_by",g),y==="desc"&&C.searchParams.append("sort_desc","1"),C.searchParams.append("size",String(c))),p&&s!==1&&C.searchParams.append("offset",String(p)),C.href}catch(C){return console.error("RouteList(fetcher)",C),a.value}}}function qe(e,n,r="data"){const a=t.unref(n),{axiosInstance:i}=G({headers:e.requestHeaders}),l=le(e,a),o=t.ref({status:L.Idle});return{fetcher:async s=>{try{o.value={status:L.Loading};let c=l(s);c.includes("filter[name]")&&(c=`${c}&page[size]=${s.pageSize}&page[number]=${s.page}`);const{data:p}=await i.get(c),g=r&&r.replace(/[^\w-_]/gi,"");let y;p[g]&&Array.isArray(p[g])?y=p[g]:Array.isArray(p)?y=p:y=Object.keys(p).length?[p]:[];const _={data:y,total:y.length,...p.offset?{pagination:{offset:p.offset}}:null};return o.value={status:L.Idle,response:_},_}catch(c){const p={data:[],total:0};return s.query&&c.response.status===404?(o.value={status:L.NoResults,response:p,error:c},p):(o.value={status:L.Error,response:p,error:c},p)}},fetcherState:o}}function ze(){const e=(r,a="_")=>r?r.split(a).map(i=>i.toLowerCase()==="id"?i.toUpperCase():i.charAt(0).toUpperCase()+i.substring(1)).join(" "):"",n=/(?:^|[\s-:'"])\w/g;return{capitalize:r=>r?r.replace(n,a=>a.toUpperCase()):"",convertKeyToTitle:e}}const se=/^[v^~<>=]*?(\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+)(?:\.([x*]|\d+))?(?:-([\da-z\-]+(?:\.[\da-z\-]+)*))?(?:\+[\da-z\-]+(?:\.[\da-z\-]+)*)?)?)?$/i,ce=e=>{if(typeof e!="string")throw new TypeError("Invalid argument expected string");const n=e.match(se);if(!n)throw new Error(`Invalid argument not valid semver ('${e}' received)`);return n.shift(),n},de=e=>e==="*"||e==="x"||e==="X",ue=e=>{const n=parseInt(e,10);return isNaN(n)?e:n},Je=(e,n)=>typeof e!=typeof n?[String(e),String(n)]:[e,n],We=(e,n)=>{if(de(e)||de(n))return 0;const[r,a]=Je(ue(e),ue(n));return r>a?1:r<a?-1:0},pe=(e,n)=>{for(let r=0;r<Math.max(e.length,n.length);r++){const a=We(e[r]||"0",n[r]||"0");if(a!==0)return a}return 0},He=(e,n)=>{const r=ce(e),a=ce(n),i=r.pop(),l=a.pop(),o=pe(r,a);return o!==0?o:i&&l?pe(i.split("."),l.split(".")):i||l?i?-1:1:0},fe=(e,n,r)=>{Ye(r);const a=He(e,n);return ye[r].includes(a)},ye={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},he=Object.keys(ye),Ye=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(he.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${he.join("|")}`)},Ge=e=>typeof e=="string"&&/^[v\d]/.test(e)&&se.test(e);function Ze(e){const{gatewayInfo:n,supportedRange:r}=e;if(!n)return!0;const{edition:a,version:i}=n;if(!Ge(i))return console.error("Invalid version"),!1;const l=r[a];if(!l)return!1;const[o,s]=l;return!(o&&fe(i,o,"<")||s&&fe(i,s,">"))}function Qe(e){const n=t.ref(0),r=t.ref(0),a=t.ref(!1);return t.watch(e,i=>{i&&!a.value&&(n.value=i.offsetWidth,r.value=i.scrollWidth,a.value=!0)}),{isTruncated:t.computed(()=>n.value<r.value)}}const Q={useAxios:G,useDebouncedFilter:Le,useDeleteUrlBuilder:Me,useErrors:Ue,useExternalLinkCreator:Re,useFetcher:qe,useFetchUrlBuilder:le,useHelpers:oe,useStringHelpers:ze,useI18n:Z,useGatewayFeatureSupported:Ze,useTruncationDetector:Qe},X=(e,n)=>{const r=e.__vccOpts||e;for(const[a,i]of n)r[a]=i;return r},Xe="#3a3f51";/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function ge(e){return typeof e>"u"||e===null}function et(e){return typeof e=="object"&&e!==null}function tt(e){return Array.isArray(e)?e:ge(e)?[]:[e]}function rt(e,n){var r,a,i,l;if(n)for(l=Object.keys(n),r=0,a=l.length;r<a;r+=1)i=l[r],e[i]=n[i];return e}function nt(e,n){var r="",a;for(a=0;a<n;a+=1)r+=e;return r}function at(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}var it=ge,ot=et,lt=tt,st=nt,ct=at,dt=rt,ee={isNothing:it,isObject:ot,toArray:lt,repeat:st,isNegativeZero:ct,extend:dt};function me(e,n){var r="",a=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(r+='in "'+e.mark.name+'" '),r+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!n&&e.mark.snippet&&(r+=`
2
2
 
3
- `+e.mark.snippet),a+" "+r):a}function z(e,n){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=n,this.message=me(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}z.prototype=Object.create(Error.prototype),z.prototype.constructor=z,z.prototype.toString=function(e){return this.name+": "+me(this,e)};var M=z,ut=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],pt=["scalar","sequence","mapping"];function ft(e){var n={};return e!==null&&Object.keys(e).forEach(function(r){e[r].forEach(function(a){n[String(a)]=r})}),n}function yt(e,n){if(n=n||{},Object.keys(n).forEach(function(r){if(ut.indexOf(r)===-1)throw new M('Unknown option "'+r+'" is met in definition of "'+e+'" YAML type.')}),this.options=n,this.tag=e,this.kind=n.kind||null,this.resolve=n.resolve||function(){return!0},this.construct=n.construct||function(r){return r},this.instanceOf=n.instanceOf||null,this.predicate=n.predicate||null,this.represent=n.represent||null,this.representName=n.representName||null,this.defaultStyle=n.defaultStyle||null,this.multi=n.multi||!1,this.styleAliases=ft(n.styleAliases||null),pt.indexOf(this.kind)===-1)throw new M('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}var A=yt;function be(e,n){var r=[];return e[n].forEach(function(a){var i=r.length;r.forEach(function(l,o){l.tag===a.tag&&l.kind===a.kind&&l.multi===a.multi&&(i=o)}),r[i]=a}),r}function ht(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},n,r;function a(i){i.multi?(e.multi[i.kind].push(i),e.multi.fallback.push(i)):e[i.kind][i.tag]=e.fallback[i.tag]=i}for(n=0,r=arguments.length;n<r;n+=1)arguments[n].forEach(a);return e}function te(e){return this.extend(e)}te.prototype.extend=function(e){var n=[],r=[];if(e instanceof A)r.push(e);else if(Array.isArray(e))r=r.concat(e);else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit)))e.implicit&&(n=n.concat(e.implicit)),e.explicit&&(r=r.concat(e.explicit));else throw new M("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");n.forEach(function(i){if(!(i instanceof A))throw new M("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(i.loadKind&&i.loadKind!=="scalar")throw new M("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(i.multi)throw new M("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),r.forEach(function(i){if(!(i instanceof A))throw new M("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var a=Object.create(te.prototype);return a.implicit=(this.implicit||[]).concat(n),a.explicit=(this.explicit||[]).concat(r),a.compiledImplicit=be(a,"implicit"),a.compiledExplicit=be(a,"explicit"),a.compiledTypeMap=ht(a.compiledImplicit,a.compiledExplicit),a};var gt=te,mt=new A("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}}),bt=new A("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}}),wt=new A("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}}),Ct=new gt({explicit:[mt,bt,wt]});function kt(e){if(e===null)return!0;var n=e.length;return n===1&&e==="~"||n===4&&(e==="null"||e==="Null"||e==="NULL")}function _t(){return null}function xt(e){return e===null}var Nt=new A("tag:yaml.org,2002:null",{kind:"scalar",resolve:kt,construct:_t,predicate:xt,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function St(e){if(e===null)return!1;var n=e.length;return n===4&&(e==="true"||e==="True"||e==="TRUE")||n===5&&(e==="false"||e==="False"||e==="FALSE")}function Tt(e){return e==="true"||e==="True"||e==="TRUE"}function At(e){return Object.prototype.toString.call(e)==="[object Boolean]"}var Et=new A("tag:yaml.org,2002:bool",{kind:"scalar",resolve:St,construct:Tt,predicate:At,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"});function It(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function Ot(e){return 48<=e&&e<=55}function jt(e){return 48<=e&&e<=57}function vt(e){if(e===null)return!1;var n=e.length,r=0,a=!1,i;if(!n)return!1;if(i=e[r],(i==="-"||i==="+")&&(i=e[++r]),i==="0"){if(r+1===n)return!0;if(i=e[++r],i==="b"){for(r++;r<n;r++)if(i=e[r],i!=="_"){if(i!=="0"&&i!=="1")return!1;a=!0}return a&&i!=="_"}if(i==="x"){for(r++;r<n;r++)if(i=e[r],i!=="_"){if(!It(e.charCodeAt(r)))return!1;a=!0}return a&&i!=="_"}if(i==="o"){for(r++;r<n;r++)if(i=e[r],i!=="_"){if(!Ot(e.charCodeAt(r)))return!1;a=!0}return a&&i!=="_"}}if(i==="_")return!1;for(;r<n;r++)if(i=e[r],i!=="_"){if(!jt(e.charCodeAt(r)))return!1;a=!0}return!(!a||i==="_")}function Bt(e){var n=e,r=1,a;if(n.indexOf("_")!==-1&&(n=n.replace(/_/g,"")),a=n[0],(a==="-"||a==="+")&&(a==="-"&&(r=-1),n=n.slice(1),a=n[0]),n==="0")return 0;if(a==="0"){if(n[1]==="b")return r*parseInt(n.slice(2),2);if(n[1]==="x")return r*parseInt(n.slice(2),16);if(n[1]==="o")return r*parseInt(n.slice(2),8)}return r*parseInt(n,10)}function $t(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!ee.isNegativeZero(e)}var Kt=new A("tag:yaml.org,2002:int",{kind:"scalar",resolve:vt,construct:Bt,predicate:$t,represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Vt=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Dt(e){return!(e===null||!Vt.test(e)||e[e.length-1]==="_")}function Pt(e){var n,r;return n=e.replace(/_/g,"").toLowerCase(),r=n[0]==="-"?-1:1,"+-".indexOf(n[0])>=0&&(n=n.slice(1)),n===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:n===".nan"?NaN:r*parseFloat(n,10)}var Lt=/^[-+]?[0-9]+e/;function Ft(e,n){var r;if(isNaN(e))switch(n){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(n){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(n){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(ee.isNegativeZero(e))return"-0.0";return r=e.toString(10),Lt.test(r)?r.replace("e",".e"):r}function Mt(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||ee.isNegativeZero(e))}var Ut=new A("tag:yaml.org,2002:float",{kind:"scalar",resolve:Dt,construct:Pt,predicate:Mt,represent:Ft,defaultStyle:"lowercase"}),Rt=Ct.extend({implicit:[Nt,Et,Kt,Ut]}),qt=Rt,we=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Ce=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function zt(e){return e===null?!1:we.exec(e)!==null||Ce.exec(e)!==null}function Jt(e){var n,r,a,i,l,o,s,c=0,p=null,g,y,_;if(n=we.exec(e),n===null&&(n=Ce.exec(e)),n===null)throw new Error("Date resolve error");if(r=+n[1],a=+n[2]-1,i=+n[3],!n[4])return new Date(Date.UTC(r,a,i));if(l=+n[4],o=+n[5],s=+n[6],n[7]){for(c=n[7].slice(0,3);c.length<3;)c+="0";c=+c}return n[9]&&(g=+n[10],y=+(n[11]||0),p=(g*60+y)*6e4,n[9]==="-"&&(p=-p)),_=new Date(Date.UTC(r,a,i,l,o,s,c)),p&&_.setTime(_.getTime()-p),_}function Wt(e){return e.toISOString()}var Ht=new A("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:zt,construct:Jt,instanceOf:Date,represent:Wt});function Yt(e){return e==="<<"||e===null}var Gt=new A("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Yt}),re=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
3
+ `+e.mark.snippet),a+" "+r):a}function z(e,n){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=n,this.message=me(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}z.prototype=Object.create(Error.prototype),z.prototype.constructor=z,z.prototype.toString=function(e){return this.name+": "+me(this,e)};var M=z,ut=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],pt=["scalar","sequence","mapping"];function ft(e){var n={};return e!==null&&Object.keys(e).forEach(function(r){e[r].forEach(function(a){n[String(a)]=r})}),n}function yt(e,n){if(n=n||{},Object.keys(n).forEach(function(r){if(ut.indexOf(r)===-1)throw new M('Unknown option "'+r+'" is met in definition of "'+e+'" YAML type.')}),this.options=n,this.tag=e,this.kind=n.kind||null,this.resolve=n.resolve||function(){return!0},this.construct=n.construct||function(r){return r},this.instanceOf=n.instanceOf||null,this.predicate=n.predicate||null,this.represent=n.represent||null,this.representName=n.representName||null,this.defaultStyle=n.defaultStyle||null,this.multi=n.multi||!1,this.styleAliases=ft(n.styleAliases||null),pt.indexOf(this.kind)===-1)throw new M('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}var A=yt;function be(e,n){var r=[];return e[n].forEach(function(a){var i=r.length;r.forEach(function(l,o){l.tag===a.tag&&l.kind===a.kind&&l.multi===a.multi&&(i=o)}),r[i]=a}),r}function ht(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},n,r;function a(i){i.multi?(e.multi[i.kind].push(i),e.multi.fallback.push(i)):e[i.kind][i.tag]=e.fallback[i.tag]=i}for(n=0,r=arguments.length;n<r;n+=1)arguments[n].forEach(a);return e}function te(e){return this.extend(e)}te.prototype.extend=function(e){var n=[],r=[];if(e instanceof A)r.push(e);else if(Array.isArray(e))r=r.concat(e);else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit)))e.implicit&&(n=n.concat(e.implicit)),e.explicit&&(r=r.concat(e.explicit));else throw new M("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");n.forEach(function(i){if(!(i instanceof A))throw new M("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(i.loadKind&&i.loadKind!=="scalar")throw new M("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(i.multi)throw new M("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),r.forEach(function(i){if(!(i instanceof A))throw new M("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var a=Object.create(te.prototype);return a.implicit=(this.implicit||[]).concat(n),a.explicit=(this.explicit||[]).concat(r),a.compiledImplicit=be(a,"implicit"),a.compiledExplicit=be(a,"explicit"),a.compiledTypeMap=ht(a.compiledImplicit,a.compiledExplicit),a};var gt=te,mt=new A("tag:yaml.org,2002:str",{kind:"scalar",construct:function(e){return e!==null?e:""}}),bt=new A("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(e){return e!==null?e:[]}}),wt=new A("tag:yaml.org,2002:map",{kind:"mapping",construct:function(e){return e!==null?e:{}}}),Ct=new gt({explicit:[mt,bt,wt]});function kt(e){if(e===null)return!0;var n=e.length;return n===1&&e==="~"||n===4&&(e==="null"||e==="Null"||e==="NULL")}function _t(){return null}function xt(e){return e===null}var Nt=new A("tag:yaml.org,2002:null",{kind:"scalar",resolve:kt,construct:_t,predicate:xt,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function St(e){if(e===null)return!1;var n=e.length;return n===4&&(e==="true"||e==="True"||e==="TRUE")||n===5&&(e==="false"||e==="False"||e==="FALSE")}function Tt(e){return e==="true"||e==="True"||e==="TRUE"}function At(e){return Object.prototype.toString.call(e)==="[object Boolean]"}var Et=new A("tag:yaml.org,2002:bool",{kind:"scalar",resolve:St,construct:Tt,predicate:At,represent:{lowercase:function(e){return e?"true":"false"},uppercase:function(e){return e?"TRUE":"FALSE"},camelcase:function(e){return e?"True":"False"}},defaultStyle:"lowercase"});function It(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}function Ot(e){return 48<=e&&e<=55}function jt(e){return 48<=e&&e<=57}function vt(e){if(e===null)return!1;var n=e.length,r=0,a=!1,i;if(!n)return!1;if(i=e[r],(i==="-"||i==="+")&&(i=e[++r]),i==="0"){if(r+1===n)return!0;if(i=e[++r],i==="b"){for(r++;r<n;r++)if(i=e[r],i!=="_"){if(i!=="0"&&i!=="1")return!1;a=!0}return a&&i!=="_"}if(i==="x"){for(r++;r<n;r++)if(i=e[r],i!=="_"){if(!It(e.charCodeAt(r)))return!1;a=!0}return a&&i!=="_"}if(i==="o"){for(r++;r<n;r++)if(i=e[r],i!=="_"){if(!Ot(e.charCodeAt(r)))return!1;a=!0}return a&&i!=="_"}}if(i==="_")return!1;for(;r<n;r++)if(i=e[r],i!=="_"){if(!jt(e.charCodeAt(r)))return!1;a=!0}return!(!a||i==="_")}function Bt(e){var n=e,r=1,a;if(n.indexOf("_")!==-1&&(n=n.replace(/_/g,"")),a=n[0],(a==="-"||a==="+")&&(a==="-"&&(r=-1),n=n.slice(1),a=n[0]),n==="0")return 0;if(a==="0"){if(n[1]==="b")return r*parseInt(n.slice(2),2);if(n[1]==="x")return r*parseInt(n.slice(2),16);if(n[1]==="o")return r*parseInt(n.slice(2),8)}return r*parseInt(n,10)}function $t(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!ee.isNegativeZero(e)}var Kt=new A("tag:yaml.org,2002:int",{kind:"scalar",resolve:vt,construct:Bt,predicate:$t,represent:{binary:function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},octal:function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},decimal:function(e){return e.toString(10)},hexadecimal:function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Vt=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Dt(e){return!(e===null||!Vt.test(e)||e[e.length-1]==="_")}function Pt(e){var n,r;return n=e.replace(/_/g,"").toLowerCase(),r=n[0]==="-"?-1:1,"+-".indexOf(n[0])>=0&&(n=n.slice(1)),n===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:n===".nan"?NaN:r*parseFloat(n,10)}var Ft=/^[-+]?[0-9]+e/;function Lt(e,n){var r;if(isNaN(e))switch(n){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(n){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(n){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(ee.isNegativeZero(e))return"-0.0";return r=e.toString(10),Ft.test(r)?r.replace("e",".e"):r}function Mt(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||ee.isNegativeZero(e))}var Ut=new A("tag:yaml.org,2002:float",{kind:"scalar",resolve:Dt,construct:Pt,predicate:Mt,represent:Lt,defaultStyle:"lowercase"}),Rt=Ct.extend({implicit:[Nt,Et,Kt,Ut]}),qt=Rt,we=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Ce=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function zt(e){return e===null?!1:we.exec(e)!==null||Ce.exec(e)!==null}function Jt(e){var n,r,a,i,l,o,s,c=0,p=null,g,y,_;if(n=we.exec(e),n===null&&(n=Ce.exec(e)),n===null)throw new Error("Date resolve error");if(r=+n[1],a=+n[2]-1,i=+n[3],!n[4])return new Date(Date.UTC(r,a,i));if(l=+n[4],o=+n[5],s=+n[6],n[7]){for(c=n[7].slice(0,3);c.length<3;)c+="0";c=+c}return n[9]&&(g=+n[10],y=+(n[11]||0),p=(g*60+y)*6e4,n[9]==="-"&&(p=-p)),_=new Date(Date.UTC(r,a,i,l,o,s,c)),p&&_.setTime(_.getTime()-p),_}function Wt(e){return e.toISOString()}var Ht=new A("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:zt,construct:Jt,instanceOf:Date,represent:Wt});function Yt(e){return e==="<<"||e===null}var Gt=new A("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Yt}),re=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
4
4
  \r`;function Zt(e){if(e===null)return!1;var n,r,a=0,i=e.length,l=re;for(r=0;r<i;r++)if(n=l.indexOf(e.charAt(r)),!(n>64)){if(n<0)return!1;a+=6}return a%8===0}function Qt(e){var n,r,a=e.replace(/[\r\n=]/g,""),i=a.length,l=re,o=0,s=[];for(n=0;n<i;n++)n%4===0&&n&&(s.push(o>>16&255),s.push(o>>8&255),s.push(o&255)),o=o<<6|l.indexOf(a.charAt(n));return r=i%4*6,r===0?(s.push(o>>16&255),s.push(o>>8&255),s.push(o&255)):r===18?(s.push(o>>10&255),s.push(o>>2&255)):r===12&&s.push(o>>4&255),new Uint8Array(s)}function Xt(e){var n="",r=0,a,i,l=e.length,o=re;for(a=0;a<l;a++)a%3===0&&a&&(n+=o[r>>18&63],n+=o[r>>12&63],n+=o[r>>6&63],n+=o[r&63]),r=(r<<8)+e[a];return i=l%3,i===0?(n+=o[r>>18&63],n+=o[r>>12&63],n+=o[r>>6&63],n+=o[r&63]):i===2?(n+=o[r>>10&63],n+=o[r>>4&63],n+=o[r<<2&63],n+=o[64]):i===1&&(n+=o[r>>2&63],n+=o[r<<4&63],n+=o[64],n+=o[64]),n}function er(e){return Object.prototype.toString.call(e)==="[object Uint8Array]"}var tr=new A("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Zt,construct:Qt,predicate:er,represent:Xt}),rr=Object.prototype.hasOwnProperty,nr=Object.prototype.toString;function ar(e){if(e===null)return!0;var n=[],r,a,i,l,o,s=e;for(r=0,a=s.length;r<a;r+=1){if(i=s[r],o=!1,nr.call(i)!=="[object Object]")return!1;for(l in i)if(rr.call(i,l))if(!o)o=!0;else return!1;if(!o)return!1;if(n.indexOf(l)===-1)n.push(l);else return!1}return!0}function ir(e){return e!==null?e:[]}var or=new A("tag:yaml.org,2002:omap",{kind:"sequence",resolve:ar,construct:ir}),lr=Object.prototype.toString;function sr(e){if(e===null)return!0;var n,r,a,i,l,o=e;for(l=new Array(o.length),n=0,r=o.length;n<r;n+=1){if(a=o[n],lr.call(a)!=="[object Object]"||(i=Object.keys(a),i.length!==1))return!1;l[n]=[i[0],a[i[0]]]}return!0}function cr(e){if(e===null)return[];var n,r,a,i,l,o=e;for(l=new Array(o.length),n=0,r=o.length;n<r;n+=1)a=o[n],i=Object.keys(a),l[n]=[i[0],a[i[0]]];return l}var dr=new A("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:sr,construct:cr}),ur=Object.prototype.hasOwnProperty;function pr(e){if(e===null)return!0;var n,r=e;for(n in r)if(ur.call(r,n)&&r[n]!==null)return!1;return!0}function fr(e){return e!==null?e:{}}var yr=new A("tag:yaml.org,2002:set",{kind:"mapping",resolve:pr,construct:fr});qt.extend({implicit:[Ht,Gt],explicit:[tr,or,dr,yr]});function ke(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
5
- `:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"…":e===95?" ":e===76?"\u2028":e===80?"\u2029":""}for(var hr=new Array(256),gr=new Array(256),R=0;R<256;R++)hr[R]=ke(R)?1:0,gr[R]=ke(R);const mr={key:0,"data-testid":"first-col"},br=t.defineComponent({__name:"EntityBaseTableCell",props:{keyName:{type:String,required:!0},rowEl:{type:[Object,null],required:!0}},setup(e){const n=e,r=t.computed(()=>{var f;return((f=n.rowEl)==null?void 0:f.querySelector(`[data-testid="${n.keyName}"]`))||null}),a=t.computed(()=>{var f;return((f=r.value)==null?void 0:f.querySelector('[data-testid="first-col"]'))||null}),i=t.computed(()=>{var f,x;const O=(f=n.rowEl)==null?void 0:f.querySelectorAll("td");return O?((x=O[0])==null?void 0:x.getAttribute("data-testid"))===n.keyName:!1});let l;const o=()=>{l&&(l.disconnect(),l=void 0)},s=()=>{var f,x,O;p.value=((f=a.value)==null?void 0:f.getBoundingClientRect().width)||0,g.value=((x=r.value)==null?void 0:x.clientWidth)||0,y.value=((O=c.value)==null?void 0:O.innerText)||""},c=t.ref({}),p=t.ref(0),g=t.ref(0),y=t.ref(""),_=t.computed(()=>[a.value,r.value]),C=t.watch(_,f=>{if(i.value&&(o(),"ResizeObserver"in window&&window)){l=new ResizeObserver(x=>{window.requestAnimationFrame(()=>{!Array.isArray(x)||!x.length||s()})});for(const x of f)x&&l.observe(x)}},{immediate:!0,flush:"post",deep:!0}),v=t.computed(()=>i.value?p.value>g.value:!1);return t.onMounted(()=>{s()}),t.onUnmounted(()=>{C()}),(f,x)=>{const O=t.resolveComponent("KTooltip");return t.openBlock(),t.createElementBlock("span",{ref_key:"contentRef",ref:c,class:"content-wrapper"},[i.value?(t.openBlock(),t.createElementBlock("span",mr,[t.createVNode(O,{"max-width":"300",placement:"bottomStart",text:v.value?y.value:""},{default:t.withCtx(()=>[t.renderSlot(f.$slots,"default",{},void 0,!0)]),_:3},8,["text"])])):t.renderSlot(f.$slots,"default",{key:1},void 0,!0)],512)}}}),wr=X(br,[["__scopeId","data-v-c4379fd4"]]),Cr={class:"toolbar-container"},kr={key:0,class:"toolbar-button-container"},_r=["data-testid"],xr=t.defineComponent({__name:"EntityBaseTable",props:{tableHeaders:{type:Object,required:!0,default:()=>({})},fetcher:{type:Function,required:!0,default:async()=>({data:[],total:0})},initialFetcherParams:{type:Object,default:null},cacheIdentifier:{type:String,default:""},fetcherCacheKey:{type:Number,default:1},isLoading:{type:Boolean,default:!1},query:{type:String,default:""},enableClientSort:{type:Boolean,default:!1},enableEntityActions:{type:Boolean,default:!0},emptyStateOptions:{type:Object,default:()=>({})},errorMessage:{type:[String,Object],default:null},disablePaginationPageJump:{type:Boolean,default:void 0},disableSorting:{type:Boolean,default:void 0},paginationType:{type:String,default:void 0},cellAttributes:{type:Function,default:()=>({})},rowAttributes:{type:Function,default:()=>({})},preferencesStorageKey:{type:String,default:"",required:!0},dropdownMenuWidth:{type:String,default:"",required:!1},title:{type:String,default:""},disableRowClick:{type:Boolean,default:!1}},emits:["click:row","sort","clear-search-input","empty-state-cta-clicked"],setup(e,{emit:n}){const r=e,a=n,{i18n:{t:i}}=Q.useI18n(),l=t.computed(()=>{var d,b;return typeof r.errorMessage=="string"?{hasError:!!r.errorMessage,title:r.errorMessage,message:void 0}:{hasError:!!r.errorMessage,title:(d=r.errorMessage)==null?void 0:d.title,message:(b=r.errorMessage)==null?void 0:b.message}}),o=t.computed(()=>r.cacheIdentifier||r.preferencesStorageKey),s=d=>d.hasData||!!r.query,c=t.computed(()=>{const d=[];return Object.keys(r.tableHeaders).forEach(b=>{const K=r.tableHeaders[b];d.push({label:K.label??b,key:b,sortable:K.sortable??!1})}),r.enableEntityActions&&d.push({key:"actions",hideLabel:!0}),d}),p=d=>({"data-rowid":d.id,"data-testid":d.name,...r.rowAttributes(d)}),g=t.ref({}),y=d=>{var b;return(b=g.value)==null?void 0:b.$el.querySelector(`[data-rowid="${d.id}"]`)},_=d=>{const b={"data-testid":d.headerKey,...r.cellAttributes(d)};return d.colIndex===0&&(b.style={maxWidth:"250px",overflowX:"hidden",textOverflow:"ellipsis"}),b},C=()=>{a("empty-state-cta-clicked"),v()},v=()=>{a("clear-search-input")},f=t.computed(()=>r.disableRowClick?void 0:(d,b)=>{a("click:row",b)}),x=d=>{a("sort",d)},{setTablePreferences:O,getTablePreferences:U}=Ie(),J=t.computed(()=>{const d=U(r.preferencesStorageKey);return{...r.initialFetcherParams,...d}}),m=d=>{r.preferencesStorageKey&&O(r.preferencesStorageKey,d)};return(d,b)=>{const K=t.resolveComponent("KIcon"),S=t.resolveComponent("KButton"),E=t.resolveComponent("KDropdown"),D=t.resolveComponent("KTable"),N=t.resolveComponent("KCard");return t.openBlock(),t.createBlock(N,{class:"kong-ui-entity-base-table",title:e.title},{default:t.withCtx(()=>[t.createVNode(D,{ref_key:"tableRefs",ref:g,"cache-identifier":o.value,"cell-attrs":_,"disable-pagination-page-jump":e.disablePaginationPageJump,"disable-sorting":e.disableSorting,"empty-state-action-button-icon":e.query?"":"plus","empty-state-action-message":e.query?t.unref(i)("baseTable.emptyState.noSearchResultsCtaText"):e.emptyStateOptions.ctaText,"empty-state-action-route":e.query?"":e.emptyStateOptions.ctaPath,"empty-state-icon":e.query?"stateNoSearchResults":"stateGruceo","empty-state-icon-size":"96","empty-state-message":e.query?t.unref(i)("baseTable.emptyState.noSearchResultsMessage"):e.emptyStateOptions.message,"empty-state-title":e.query?t.unref(i)("baseTable.emptyState.noSearchResultsTitle"):e.emptyStateOptions.title,"enable-client-sort":e.enableClientSort,"error-state-message":l.value.message,"error-state-title":l.value.title,fetcher:e.fetcher,"fetcher-cache-key":String(e.fetcherCacheKey),"has-error":l.value.hasError,headers:c.value,"hide-pagination-when-optional":"","initial-fetcher-params":J.value,"is-loading":e.isLoading,"pagination-type":e.paginationType,"row-attrs":p,"search-input":e.query,onKtableEmptyStateCtaClicked:C,"onRow:click":f.value,onSort:b[0]||(b[0]=T=>x(T)),"onUpdate:tablePreferences":m},t.createSlots({toolbar:t.withCtx(({state:T})=>[t.withDirectives(t.createElementVNode("div",Cr,[t.renderSlot(d.$slots,"toolbar-filter",{},void 0,!0),d.$slots["toolbar-button"]?(t.openBlock(),t.createElementBlock("div",kr,[t.renderSlot(d.$slots,"toolbar-button",{},void 0,!0)])):t.createCommentVNode("",!0)],512),[[t.vShow,s(T)]])]),actions:t.withCtx(({row:T,rowKey:B,rowValue:P})=>[t.createElementVNode("div",{class:"actions-container","data-testid":T.name},[t.createVNode(E,{"kpop-attributes":{placement:"bottomEnd"},width:e.dropdownMenuWidth},{items:t.withCtx(()=>[t.renderSlot(d.$slots,"actions",{row:T,rowKey:B,rowValue:P},void 0,!0)]),default:t.withCtx(()=>[t.createVNode(S,{class:"actions-trigger","data-testid":"overflow-actions-button",size:"small"},{icon:t.withCtx(()=>[t.createVNode(K,{color:t.unref(Xe),icon:"more",size:"16"},null,8,["color"])]),_:1})]),_:2},1032,["width"])],8,_r)]),_:2},[t.renderList(e.tableHeaders,(T,B)=>({name:B,fn:t.withCtx(({row:P,rowKey:u,rowValue:w})=>[t.createVNode(wr,{"key-name":String(B),"row-el":y(P)},{default:t.withCtx(()=>[t.renderSlot(d.$slots,B,{row:P,rowKey:u,rowValue:w},()=>[t.createTextVNode(t.toDisplayString(w),1)],!0)]),_:2},1032,["key-name","row-el"])])}))]),1032,["cache-identifier","disable-pagination-page-jump","disable-sorting","empty-state-action-button-icon","empty-state-action-message","empty-state-action-route","empty-state-icon","empty-state-message","empty-state-title","enable-client-sort","error-state-message","error-state-title","fetcher","fetcher-cache-key","has-error","headers","initial-fetcher-params","is-loading","pagination-type","search-input","onRow:click"])]),_:3},8,["title"])}}}),Nr=X(xr,[["__scopeId","data-v-ecfaa7cf"]]),Sr={key:0,class:"kong-ui-entity-delete-error"},Tr={key:1,class:"description"},Ar=t.defineComponent({__name:"EntityDeleteModal",props:{visible:{type:Boolean,required:!0,default:!1},title:{type:String,default:"Delete"},entityType:{type:String,required:!0},entityName:{type:String,default:""},needConfirm:{type:Boolean,default:!0},description:{type:String,default:""},actionPending:{type:Boolean,default:!1},error:{type:String,default:""}},emits:["cancel","proceed"],setup(e,{emit:n}){const{i18nT:r}=Q.useI18n(),a=e,i=n,l=t.computed(()=>a.needConfirm?a.entityName:""),o=()=>{i("cancel")},s=()=>{i("proceed")};return(c,p)=>{const g=t.resolveComponent("KAlert"),y=t.resolveComponent("KPrompt");return t.openBlock(),t.createBlock(y,{"action-button-appearance":"danger","action-button-disabled":e.actionPending,"action-button-text":"Yes, delete",class:"kong-ui-entity-delete-modal","confirmation-text":l.value,title:e.title,visible:e.visible,onCancel:o,onProceed:s},{default:t.withCtx(()=>[e.error?(t.openBlock(),t.createElementBlock("div",Sr,[t.createVNode(g,{appearance:"danger"},{alertMessage:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.error),1)]),_:1})])):t.createCommentVNode("",!0),t.createVNode(t.unref(r),{class:"message",keypath:a.entityName?"deleteModal.messageWithName":"deleteModal.message",tag:"p"},t.createSlots({entityType:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(a.entityType),1)]),_:2},[a.entityName?{name:"entityName",fn:t.withCtx(()=>[t.createElementVNode("strong",null,t.toDisplayString(a.entityName),1)]),key:"0"}:void 0]),1032,["keypath"]),a.description||c.$slots.description?(t.openBlock(),t.createElementBlock("div",Tr,[t.renderSlot(c.$slots,"description",{},()=>[t.createElementVNode("p",null,t.toDisplayString(a.description),1)],!0)])):t.createCommentVNode("",!0)]),_:3},8,["action-button-disabled","confirmation-text","title","visible"])}}}),Er=X(Ar,[["__scopeId","data-v-efe8f34b"]]),ne=t.defineComponent({__name:"PermissionsWrapper",props:{authFunction:{type:Function,required:!0,default:async()=>!0},forceShow:{type:Boolean,default:!1}},setup(e){const n=e,r=t.ref(void 0),a=t.computed(()=>r.value===!0||r.value!==void 0&&n.forceShow===!0);return t.watch(()=>n.authFunction,async()=>{r.value=await n.authFunction()},{immediate:!0}),(i,l)=>a.value?t.renderSlot(i.$slots,"default",{key:0,isAllowed:r.value}):t.createCommentVNode("",!0)}}),{useAxios:Ir,useDeleteUrlBuilder:Or,useErrors:Dr,useExternalLinkCreator:Pr,useFetchUrlBuilder:Lr,useFetcher:jr,useDebouncedFilter:Fr,useStringHelpers:Mr,useHelpers:Ur,useGatewayFeatureSupported:Rr,useTruncationDetector:qr}=Q,vr={class:"kong-ui-entities-consumer-credentials-list"},Br={key:1},$r=((e,n)=>{const r=e.__vccOpts||e;for(const[a,i]of n)r[a]=i;return r})(t.defineComponent({__name:"ConsumerCredentialList",props:{config:{type:Object,required:!0,validator:e=>!(!e||!["konnect","kongManager"].includes(e==null?void 0:e.app)||!e.createRoute||!e.getEditRoute)},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},useActionOutside:{type:Boolean,default:!1}},emits:["error","copy:success","copy:error","delete:success"],setup(e,{emit:n}){const r=n,a=e,{i18n:{t:i,formatUnixTimeStamp:l}}=Ne.useI18n(),{axiosInstance:o}=Ir({headers:a.config.requestHeaders}),s=t.ref(1),c={acls:{group:{label:i("credentials.list.table_headers.acls.group")},created_at:{label:i("credentials.list.table_headers.acls.created_at")},tags:{label:i("credentials.list.table_headers.acls.tags")}},"basic-auth":{password:{label:i("credentials.list.table_headers.basic-auth.password")},username:{label:i("credentials.list.table_headers.basic-auth.username")},created_at:{label:i("credentials.list.table_headers.basic-auth.created_at")},tags:{label:i("credentials.list.table_headers.basic-auth.tags")}},"key-auth":{key:{label:i("credentials.list.table_headers.key-auth.key")},created_at:{label:i("credentials.list.table_headers.key-auth.created_at")},tags:{label:i("credentials.list.table_headers.key-auth.tags")}},"key-auth-enc":{key:{label:i("credentials.list.table_headers.key-auth-enc.key")},created_at:{label:i("credentials.list.table_headers.key-auth-enc.created_at")},tags:{label:i("credentials.list.table_headers.key-auth-enc.tags")}},oauth2:{name:{label:i("credentials.list.table_headers.oauth2.name")},client_id:{label:i("credentials.list.table_headers.oauth2.client_id")},client_secret:{label:i("credentials.list.table_headers.oauth2.client_secret")},created_at:{label:i("credentials.list.table_headers.oauth2.created_at")},tags:{label:i("credentials.list.table_headers.oauth2.tags")}},"hmac-auth":{username:{label:i("credentials.list.table_headers.hmac-auth.username")},secret:{label:i("credentials.list.table_headers.hmac-auth.secret")},created_at:{label:i("credentials.list.table_headers.hmac-auth.created_at")},tags:{label:i("credentials.list.table_headers.hmac-auth.tags")}},jwt:{key:{label:i("credentials.list.table_headers.jwt.key")},algorithm:{label:i("credentials.list.table_headers.jwt.algorithm")},created_at:{label:i("credentials.list.table_headers.jwt.created_at")},tags:{label:i("credentials.list.table_headers.jwt.tags")}}},p=t.computed(()=>c[a.config.plugin]),g=t.computed(()=>{let u=`${a.config.apiBaseUrl}${Se.list[a.config.app]}`;return a.config.app==="konnect"?u=u.replace(/{controlPlaneId}/gi,a.config.controlPlaneId||"").replace(/{consumerId}/gi,a.config.consumerId||"").replace(/{plugin}/gi,a.config.plugin||""):a.config.app==="kongManager"&&(u=u.replace(/\/{workspace}/gi,a.config.workspace?`/${a.config.workspace}`:"").replace(/{consumerId}/gi,a.config.consumerId||"").replace(/{plugin}/gi,a.config.plugin||"")),u}),{fetcher:y,fetcherState:_}=jr(a.config,g),C=()=>{s.value++},v=t.ref(null),f=(u,w,$)=>{const I=w?u[w]:JSON.stringify(u);if(!$(I)){U(u,w);return}O(u,w)},x=(u,w,$)=>{const{type:I}=u;I==="success"?O(w,$):U(w,$)},O=(u,w)=>{r("copy:success",{entity:u,field:w,message:w?i("credentials.copy.success",{val:u[w]}):i("credentials.copy.success_brief")})},U=(u,w)=>{r("copy:error",{entity:u,field:w,message:i("credentials.error.copy")})},J=u=>({label:i("credentials.actions.edit"),to:a.config.getEditRoute(u)}),m=t.ref(void 0),d=t.ref(!1),b=t.ref(!1),K=t.ref(""),S=Or(a.config,g.value),E=t.computed(()=>ie[a.config.plugin]),D=u=>{m.value=u,d.value=!0},N=()=>{d.value=!1},T=async()=>{var u,w,$;if((u=m.value)!=null&&u.id){b.value=!0;try{await o.delete(S(m.value.id)),b.value=!1,d.value=!1,s.value++,r("delete:success",m.value)}catch(I){K.value=(($=(w=I.response)==null?void 0:w.data)==null?void 0:$.message)||I.message||i("credentials.error.delete"),r("error",I)}finally{b.value=!1}}},B=t.ref(!0);t.watch(_,u=>{var w,$,I,H;if(Array.isArray((w=u==null?void 0:u.response)==null?void 0:w.data)&&(B.value=u.response.data.length>0),u.status===F.Error){v.value={title:i("credentials.error.general")},(H=(I=($=u.error)==null?void 0:$.response)==null?void 0:I.data)!=null&&H.message&&(v.value.message=u.error.response.data.message),r("error",u.error);return}v.value=null});const P=t.ref({ctaPath:a.config.createRoute,ctaText:void 0,message:"",title:i("credentials.title")});return t.onBeforeMount(async()=>{await a.canCreate()&&(P.value.title=i(`credentials.list.empty_state.${a.config.plugin}.title`),P.value.ctaText=i(`credentials.list.empty_state.${a.config.plugin}.cta`))}),(u,w)=>{const $=t.resolveComponent("KButton"),I=t.resolveComponent("CopyUuid"),H=t.resolveComponent("KBadge"),Kr=t.resolveComponent("KTruncate"),L=t.resolveComponent("KDropdownItem"),q=t.resolveComponent("KClipboardProvider");return t.openBlock(),t.createElementBlock("div",vr,[t.createVNode(t.unref(Nr),{"cache-identifier":e.cacheIdentifier,"disable-pagination-page-jump":"","disable-row-click":"","disable-sorting":"","empty-state-options":P.value,"enable-entity-actions":"","error-message":v.value,fetcher:t.unref(y),"fetcher-cache-key":s.value,"pagination-type":"offset","preferences-storage-key":"kong-ui-entities-consumer-credentials-list","table-headers":p.value,"use-action-outside":e.useActionOutside,onSort:C},{"toolbar-button":t.withCtx(()=>[(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.useActionOutside?"Teleport":"div"),{to:e.useActionOutside?"#kong-ui-app-page-header-action-button":void 0},{default:t.withCtx(()=>[t.createVNode(t.unref(ne),{"auth-function":()=>e.canCreate()},{default:t.withCtx(()=>[t.withDirectives(t.createVNode($,{appearance:"primary","data-testid":"toolbar-add-credential",icon:"plus",to:e.config.createRoute},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)(`credentials.list.toolbar_actions.${e.config.plugin}.new`)),1)]),_:1},8,["to"]),[[t.vShow,B.value]])]),_:1},8,["auth-function"])]),_:1},8,["to"]))]),group:t.withCtx(({rowValue:h})=>[t.createElementVNode("b",null,t.toDisplayString(h??"-"),1)]),name:t.withCtx(({rowValue:h})=>[t.createElementVNode("b",null,t.toDisplayString(h??"-"),1)]),username:t.withCtx(({rowValue:h})=>[t.createElementVNode("span",null,t.toDisplayString(h??"-"),1)]),password:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:j=>x(j,h,"password"),uuid:k},null,8,["notify","uuid"])]),key:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:j=>x(j,h,"key"),uuid:k},null,8,["notify","uuid"])]),client_secret:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:j=>x(j,h,"client_secret"),uuid:k},null,8,["notify","uuid"])]),secret:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:j=>x(j,h,"secret"),uuid:k},null,8,["notify","uuid"])]),created_at:t.withCtx(({rowValue:h})=>[t.createTextVNode(t.toDisplayString(t.unref(l)(h)),1)]),tags:t.withCtx(({rowValue:h})=>[(h==null?void 0:h.length)>0?(t.openBlock(),t.createBlock(Kr,{key:0},{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(h,k=>(t.openBlock(),t.createBlock(H,{key:k,onClick:w[0]||(w[0]=t.withModifiers(()=>{},["stop"]))},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(k),1)]),_:2},1024))),128))]),_:2},1024)):(t.openBlock(),t.createElementBlock("span",Br,"-"))]),actions:t.withCtx(({row:h})=>[t.createVNode(q,null,{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(L,{"data-testid":"action-entity-copy-id",onClick:j=>f(h,"id",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_id")),1)]),_:2},1032,["onClick"])]),_:2},1024),e.config.plugin==="basic-auth"?(t.openBlock(),t.createBlock(q,{key:0},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(L,{"data-testid":"action-entity-copy-credential",onClick:j=>f(h,"password",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_credential")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),["key-auth","key-auth-enc","jwt"].includes(e.config.plugin)?(t.openBlock(),t.createBlock(q,{key:1},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(L,{"data-testid":"action-entity-copy-key",onClick:j=>f(h,"key",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_key")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),e.config.plugin==="oauth2"?(t.openBlock(),t.createBlock(q,{key:2},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(L,{"data-testid":"action-entity-copy-secret",onClick:j=>f(h,"client_secret",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_secret")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),e.config.plugin==="hmac-auth"?(t.openBlock(),t.createBlock(q,{key:3},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(L,{"data-testid":"action-entity-copy-secret",onClick:j=>f(h,"secret",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_secret")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),t.createVNode(q,null,{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(L,{"data-testid":"action-entity-copy-json",onClick:j=>f(h,void 0,k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_json")),1)]),_:2},1032,["onClick"])]),_:2},1024),t.createVNode(t.unref(ne),{"auth-function":()=>e.canEdit(h)},{default:t.withCtx(()=>[t.createVNode(L,{"data-testid":"action-entity-edit","has-divider":"",item:J(h.id)},null,8,["item"])]),_:2},1032,["auth-function"]),t.createVNode(t.unref(ne),{"auth-function":()=>e.canDelete(h)},{default:t.withCtx(()=>[t.createVNode(L,{danger:"","data-testid":"action-entity-delete","has-divider":"",onClick:k=>D(h)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.delete")),1)]),_:2},1032,["onClick"])]),_:2},1032,["auth-function"])]),_:1},8,["cache-identifier","empty-state-options","error-message","fetcher","fetcher-cache-key","table-headers","use-action-outside"]),t.createVNode(t.unref(Er),{"action-pending":b.value,description:t.unref(i)("credentials.delete.description"),"entity-type":E.value,error:K.value,title:t.unref(i)(`credentials.delete.${e.config.plugin}.title`),visible:d.value,onCancel:N,onProceed:T},null,8,["action-pending","description","entity-type","error","title","visible"])])}}}),[["__scopeId","data-v-6e469a8e"]]);V.ConsumerCredentialList=$r,Object.defineProperty(V,Symbol.toStringTag,{value:"Module"})});
5
+ `:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"…":e===95?" ":e===76?"\u2028":e===80?"\u2029":""}for(var hr=new Array(256),gr=new Array(256),R=0;R<256;R++)hr[R]=ke(R)?1:0,gr[R]=ke(R);const mr={key:0,"data-testid":"first-col"},br=t.defineComponent({__name:"EntityBaseTableCell",props:{keyName:{type:String,required:!0},rowEl:{type:[Object,null],required:!0}},setup(e){const n=e,r=t.computed(()=>{var f;return((f=n.rowEl)==null?void 0:f.querySelector(`[data-testid="${n.keyName}"]`))||null}),a=t.computed(()=>{var f;return((f=r.value)==null?void 0:f.querySelector('[data-testid="first-col"]'))||null}),i=t.computed(()=>{var f,x;const O=(f=n.rowEl)==null?void 0:f.querySelectorAll("td");return O?((x=O[0])==null?void 0:x.getAttribute("data-testid"))===n.keyName:!1});let l;const o=()=>{l&&(l.disconnect(),l=void 0)},s=()=>{var f,x,O;p.value=((f=a.value)==null?void 0:f.getBoundingClientRect().width)||0,g.value=((x=r.value)==null?void 0:x.clientWidth)||0,y.value=((O=c.value)==null?void 0:O.innerText)||""},c=t.ref({}),p=t.ref(0),g=t.ref(0),y=t.ref(""),_=t.computed(()=>[a.value,r.value]),C=t.watch(_,f=>{if(i.value&&(o(),"ResizeObserver"in window&&window)){l=new ResizeObserver(x=>{window.requestAnimationFrame(()=>{!Array.isArray(x)||!x.length||s()})});for(const x of f)x&&l.observe(x)}},{immediate:!0,flush:"post",deep:!0}),B=t.computed(()=>i.value?p.value>g.value:!1);return t.onMounted(()=>{s()}),t.onUnmounted(()=>{C()}),(f,x)=>{const O=t.resolveComponent("KTooltip");return t.openBlock(),t.createElementBlock("span",{ref_key:"contentRef",ref:c,class:"content-wrapper"},[i.value?(t.openBlock(),t.createElementBlock("span",mr,[t.createVNode(O,{"max-width":"300",placement:"bottomStart",text:B.value?y.value:""},{default:t.withCtx(()=>[t.renderSlot(f.$slots,"default",{},void 0,!0)]),_:3},8,["text"])])):t.renderSlot(f.$slots,"default",{key:1},void 0,!0)],512)}}}),wr=X(br,[["__scopeId","data-v-c4379fd4"]]),Cr={class:"toolbar-container"},kr={key:0,class:"toolbar-button-container"},_r=["data-testid"],xr=t.defineComponent({__name:"EntityBaseTable",props:{tableHeaders:{type:Object,required:!0,default:()=>({})},fetcher:{type:Function,required:!0,default:async()=>({data:[],total:0})},initialFetcherParams:{type:Object,default:null},cacheIdentifier:{type:String,default:""},fetcherCacheKey:{type:Number,default:1},isLoading:{type:Boolean,default:!1},query:{type:String,default:""},enableClientSort:{type:Boolean,default:!1},enableEntityActions:{type:Boolean,default:!0},emptyStateOptions:{type:Object,default:()=>({})},errorMessage:{type:[String,Object],default:null},disablePaginationPageJump:{type:Boolean,default:void 0},disableSorting:{type:Boolean,default:void 0},paginationType:{type:String,default:void 0},cellAttributes:{type:Function,default:()=>({})},rowAttributes:{type:Function,default:()=>({})},preferencesStorageKey:{type:String,default:"",required:!0},dropdownMenuWidth:{type:String,default:"",required:!1},title:{type:String,default:""},disableRowClick:{type:Boolean,default:!1}},emits:["click:row","sort","clear-search-input","empty-state-cta-clicked"],setup(e,{emit:n}){const r=e,a=n,{i18n:{t:i}}=Q.useI18n(),l=t.computed(()=>{var d,w;return typeof r.errorMessage=="string"?{hasError:!!r.errorMessage,title:r.errorMessage,message:void 0}:{hasError:!!r.errorMessage,title:(d=r.errorMessage)==null?void 0:d.title,message:(w=r.errorMessage)==null?void 0:w.message}}),o=t.computed(()=>r.cacheIdentifier||r.preferencesStorageKey),s=d=>d.hasData||!!r.query,c=t.computed(()=>{const d=[];return Object.keys(r.tableHeaders).forEach(w=>{const K=r.tableHeaders[w];d.push({label:K.label??w,key:w,sortable:K.sortable??!1})}),r.enableEntityActions&&d.push({key:"actions",hideLabel:!0}),d}),p=d=>({"data-rowid":d.id,"data-testid":d.name,...r.rowAttributes(d)}),g=t.ref({}),y=d=>{var w;return(w=g.value)==null?void 0:w.$el.querySelector(`[data-rowid="${d.id}"]`)},_=d=>{const w={"data-testid":d.headerKey,...r.cellAttributes(d)};return d.colIndex===0&&(w.style={maxWidth:"250px",overflowX:"hidden",textOverflow:"ellipsis"}),w},C=()=>{a("empty-state-cta-clicked"),B()},B=()=>{a("clear-search-input")},f=t.computed(()=>r.disableRowClick?void 0:(d,w)=>{a("click:row",w)}),x=d=>{a("sort",d)},{setTablePreferences:O,getTablePreferences:U}=Ie(),J=t.computed(()=>{const d=U(r.preferencesStorageKey);return{...r.initialFetcherParams,...d}}),m=d=>{r.preferencesStorageKey&&O(r.preferencesStorageKey,d)};return(d,w)=>{const K=t.resolveComponent("KIcon"),S=t.resolveComponent("KButton"),E=t.resolveComponent("KDropdown"),D=t.resolveComponent("KTable"),N=t.resolveComponent("KCard");return t.openBlock(),t.createBlock(N,{class:"kong-ui-entity-base-table",title:e.title},{default:t.withCtx(()=>[t.createVNode(D,{ref_key:"tableRefs",ref:g,"cache-identifier":o.value,"cell-attrs":_,"disable-pagination-page-jump":e.disablePaginationPageJump,"disable-sorting":e.disableSorting,"empty-state-action-button-icon":e.query?"":"plus","empty-state-action-message":e.query?t.unref(i)("baseTable.emptyState.noSearchResultsCtaText"):e.emptyStateOptions.ctaText,"empty-state-action-route":e.query?"":e.emptyStateOptions.ctaPath,"empty-state-icon":e.query?"stateNoSearchResults":"stateGruceo","empty-state-icon-size":"96","empty-state-message":e.query?t.unref(i)("baseTable.emptyState.noSearchResultsMessage"):e.emptyStateOptions.message,"empty-state-title":e.query?t.unref(i)("baseTable.emptyState.noSearchResultsTitle"):e.emptyStateOptions.title,"enable-client-sort":e.enableClientSort,"error-state-message":l.value.message,"error-state-title":l.value.title,fetcher:e.fetcher,"fetcher-cache-key":String(e.fetcherCacheKey),"has-error":l.value.hasError,headers:c.value,"hide-pagination-when-optional":"","initial-fetcher-params":J.value,"is-loading":e.isLoading,"pagination-type":e.paginationType,"row-attrs":p,"search-input":e.query,onKtableEmptyStateCtaClicked:C,"onRow:click":f.value,onSort:w[0]||(w[0]=T=>x(T)),"onUpdate:tablePreferences":m},t.createSlots({toolbar:t.withCtx(({state:T})=>[t.withDirectives(t.createElementVNode("div",Cr,[t.renderSlot(d.$slots,"toolbar-filter",{},void 0,!0),d.$slots["toolbar-button"]?(t.openBlock(),t.createElementBlock("div",kr,[t.renderSlot(d.$slots,"toolbar-button",{},void 0,!0)])):t.createCommentVNode("",!0)],512),[[t.vShow,s(T)]])]),actions:t.withCtx(({row:T,rowKey:$,rowValue:P})=>[t.createElementVNode("div",{class:"actions-container","data-testid":T.name},[t.createVNode(E,{"kpop-attributes":{placement:"bottomEnd"},width:e.dropdownMenuWidth},{items:t.withCtx(()=>[t.renderSlot(d.$slots,"actions",{row:T,rowKey:$,rowValue:P},void 0,!0)]),default:t.withCtx(()=>[t.createVNode(S,{class:"actions-trigger","data-testid":"overflow-actions-button",size:"small"},{icon:t.withCtx(()=>[t.createVNode(K,{color:t.unref(Xe),icon:"more",size:"16"},null,8,["color"])]),_:1})]),_:2},1032,["width"])],8,_r)]),_:2},[t.renderList(e.tableHeaders,(T,$)=>({name:$,fn:t.withCtx(({row:P,rowKey:u,rowValue:b})=>[t.createVNode(wr,{"key-name":String($),"row-el":y(P)},{default:t.withCtx(()=>[t.renderSlot(d.$slots,$,{row:P,rowKey:u,rowValue:b},()=>[t.createTextVNode(t.toDisplayString(b),1)],!0)]),_:2},1032,["key-name","row-el"])])}))]),1032,["cache-identifier","disable-pagination-page-jump","disable-sorting","empty-state-action-button-icon","empty-state-action-message","empty-state-action-route","empty-state-icon","empty-state-message","empty-state-title","enable-client-sort","error-state-message","error-state-title","fetcher","fetcher-cache-key","has-error","headers","initial-fetcher-params","is-loading","pagination-type","search-input","onRow:click"])]),_:3},8,["title"])}}}),Nr=X(xr,[["__scopeId","data-v-ecfaa7cf"]]),Sr={key:0,class:"kong-ui-entity-delete-error"},Tr={key:1,class:"description"},Ar=t.defineComponent({__name:"EntityDeleteModal",props:{visible:{type:Boolean,required:!0,default:!1},title:{type:String,default:"Delete"},entityType:{type:String,required:!0},entityName:{type:String,default:""},needConfirm:{type:Boolean,default:!0},description:{type:String,default:""},actionPending:{type:Boolean,default:!1},error:{type:String,default:""}},emits:["cancel","proceed"],setup(e,{emit:n}){const{i18nT:r}=Q.useI18n(),a=e,i=n,l=t.computed(()=>a.needConfirm?a.entityName:""),o=()=>{i("cancel")},s=()=>{i("proceed")};return(c,p)=>{const g=t.resolveComponent("KAlert"),y=t.resolveComponent("KPrompt");return t.openBlock(),t.createBlock(y,{"action-button-appearance":"danger","action-button-disabled":e.actionPending,"action-button-text":"Yes, delete",class:"kong-ui-entity-delete-modal","confirmation-text":l.value,title:e.title,visible:e.visible,onCancel:o,onProceed:s},{default:t.withCtx(()=>[e.error?(t.openBlock(),t.createElementBlock("div",Sr,[t.createVNode(g,{appearance:"danger"},{alertMessage:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(e.error),1)]),_:1})])):t.createCommentVNode("",!0),t.createVNode(t.unref(r),{class:"message",keypath:a.entityName?"deleteModal.messageWithName":"deleteModal.message",tag:"p"},t.createSlots({entityType:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(a.entityType),1)]),_:2},[a.entityName?{name:"entityName",fn:t.withCtx(()=>[t.createElementVNode("strong",null,t.toDisplayString(a.entityName),1)]),key:"0"}:void 0]),1032,["keypath"]),a.description||c.$slots.description?(t.openBlock(),t.createElementBlock("div",Tr,[t.renderSlot(c.$slots,"description",{},()=>[t.createElementVNode("p",null,t.toDisplayString(a.description),1)],!0)])):t.createCommentVNode("",!0)]),_:3},8,["action-button-disabled","confirmation-text","title","visible"])}}}),Er=X(Ar,[["__scopeId","data-v-efe8f34b"]]),ne=t.defineComponent({__name:"PermissionsWrapper",props:{authFunction:{type:Function,required:!0,default:async()=>!0},forceShow:{type:Boolean,default:!1}},setup(e){const n=e,r=t.ref(void 0),a=t.computed(()=>r.value===!0||r.value!==void 0&&n.forceShow===!0);return t.watch(()=>n.authFunction,async()=>{r.value=await n.authFunction()},{immediate:!0}),(i,l)=>a.value?t.renderSlot(i.$slots,"default",{key:0,isAllowed:r.value}):t.createCommentVNode("",!0)}}),{useAxios:Ir,useDeleteUrlBuilder:Or,useErrors:Dr,useExternalLinkCreator:Pr,useFetchUrlBuilder:Fr,useFetcher:jr,useDebouncedFilter:Lr,useStringHelpers:Mr,useHelpers:Ur,useGatewayFeatureSupported:Rr,useTruncationDetector:qr}=Q,vr={class:"kong-ui-entities-consumer-credentials-list"},Br={key:1},$r=((e,n)=>{const r=e.__vccOpts||e;for(const[a,i]of n)r[a]=i;return r})(t.defineComponent({__name:"ConsumerCredentialList",props:{config:{type:Object,required:!0,validator:e=>!(!e||!["konnect","kongManager"].includes(e==null?void 0:e.app)||!e.createRoute||!e.getEditRoute)},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},useActionOutside:{type:Boolean,default:!1}},emits:["error","copy:success","copy:error","delete:success"],setup(e,{emit:n}){const r=n,a=e,{i18n:{t:i,formatUnixTimeStamp:l}}=Ne.useI18n(),{axiosInstance:o}=Ir({headers:a.config.requestHeaders}),s=t.ref(1),c={acls:{group:{label:i("credentials.list.table_headers.acls.group")},created_at:{label:i("credentials.list.table_headers.acls.created_at")},tags:{label:i("credentials.list.table_headers.acls.tags")}},"basic-auth":{password:{label:i("credentials.list.table_headers.basic-auth.password")},username:{label:i("credentials.list.table_headers.basic-auth.username")},created_at:{label:i("credentials.list.table_headers.basic-auth.created_at")},tags:{label:i("credentials.list.table_headers.basic-auth.tags")}},"key-auth":{key:{label:i("credentials.list.table_headers.key-auth.key")},created_at:{label:i("credentials.list.table_headers.key-auth.created_at")},tags:{label:i("credentials.list.table_headers.key-auth.tags")}},"key-auth-enc":{key:{label:i("credentials.list.table_headers.key-auth-enc.key")},created_at:{label:i("credentials.list.table_headers.key-auth-enc.created_at")},tags:{label:i("credentials.list.table_headers.key-auth-enc.tags")}},oauth2:{name:{label:i("credentials.list.table_headers.oauth2.name")},client_id:{label:i("credentials.list.table_headers.oauth2.client_id")},client_secret:{label:i("credentials.list.table_headers.oauth2.client_secret")},created_at:{label:i("credentials.list.table_headers.oauth2.created_at")},tags:{label:i("credentials.list.table_headers.oauth2.tags")}},"hmac-auth":{username:{label:i("credentials.list.table_headers.hmac-auth.username")},secret:{label:i("credentials.list.table_headers.hmac-auth.secret")},created_at:{label:i("credentials.list.table_headers.hmac-auth.created_at")},tags:{label:i("credentials.list.table_headers.hmac-auth.tags")}},jwt:{key:{label:i("credentials.list.table_headers.jwt.key")},algorithm:{label:i("credentials.list.table_headers.jwt.algorithm")},created_at:{label:i("credentials.list.table_headers.jwt.created_at")},tags:{label:i("credentials.list.table_headers.jwt.tags")}}},p=t.computed(()=>c[a.config.plugin]),g=t.computed(()=>{let u=`${a.config.apiBaseUrl}${Se.list[a.config.app]}`;return a.config.app==="konnect"?u=u.replace(/{controlPlaneId}/gi,a.config.controlPlaneId||"").replace(/{consumerId}/gi,a.config.consumerId||"").replace(/{plugin}/gi,a.config.plugin||""):a.config.app==="kongManager"&&(u=u.replace(/\/{workspace}/gi,a.config.workspace?`/${a.config.workspace}`:"").replace(/{consumerId}/gi,a.config.consumerId||"").replace(/{plugin}/gi,a.config.plugin||"")),u}),{fetcher:y,fetcherState:_}=jr(a.config,g),C=()=>{s.value++},B=t.ref(null),f=(u,b,j)=>{const I=b?u[b]:JSON.stringify(u);if(!j(I)){U(u,b);return}O(u,b)},x=(u,b,j)=>{const{type:I}=u;I==="success"?O(b,j):U(b,j)},O=(u,b)=>{r("copy:success",{entity:u,field:b,message:b&&!["password","key","client_secret","secret"].includes(b)?i("credentials.copy.success",{val:u[b]}):i("credentials.copy.success_brief")})},U=(u,b)=>{r("copy:error",{entity:u,field:b,message:i("credentials.error.copy")})},J=u=>({label:i("credentials.actions.edit"),to:a.config.getEditRoute(u)}),m=t.ref(void 0),d=t.ref(!1),w=t.ref(!1),K=t.ref(""),S=Or(a.config,g.value),E=t.computed(()=>ie[a.config.plugin]),D=u=>{m.value=u,d.value=!0},N=()=>{d.value=!1},T=async()=>{var u,b,j;if((u=m.value)!=null&&u.id){w.value=!0;try{await o.delete(S(m.value.id)),w.value=!1,d.value=!1,s.value++,r("delete:success",m.value)}catch(I){K.value=((j=(b=I.response)==null?void 0:b.data)==null?void 0:j.message)||I.message||i("credentials.error.delete"),r("error",I)}finally{w.value=!1}}},$=t.ref(!0);t.watch(_,u=>{var b,j,I,H;if(Array.isArray((b=u==null?void 0:u.response)==null?void 0:b.data)&&($.value=u.response.data.length>0),u.status===L.Error){B.value={title:i("credentials.error.general")},(H=(I=(j=u.error)==null?void 0:j.response)==null?void 0:I.data)!=null&&H.message&&(B.value.message=u.error.response.data.message),r("error",u.error);return}B.value=null});const P=t.ref({ctaPath:a.config.createRoute,ctaText:void 0,message:"",title:i("credentials.title")});return t.onBeforeMount(async()=>{await a.canCreate()&&(P.value.title=i(`credentials.list.empty_state.${a.config.plugin}.title`),P.value.ctaText=i(`credentials.list.empty_state.${a.config.plugin}.cta`))}),(u,b)=>{const j=t.resolveComponent("KButton"),I=t.resolveComponent("CopyUuid"),H=t.resolveComponent("KBadge"),Kr=t.resolveComponent("KTruncate"),F=t.resolveComponent("KDropdownItem"),q=t.resolveComponent("KClipboardProvider");return t.openBlock(),t.createElementBlock("div",vr,[t.createVNode(t.unref(Nr),{"cache-identifier":e.cacheIdentifier,"disable-pagination-page-jump":"","disable-row-click":"","disable-sorting":"","empty-state-options":P.value,"enable-entity-actions":"","error-message":B.value,fetcher:t.unref(y),"fetcher-cache-key":s.value,"pagination-type":"offset","preferences-storage-key":"kong-ui-entities-consumer-credentials-list","table-headers":p.value,"use-action-outside":e.useActionOutside,onSort:C},{"toolbar-button":t.withCtx(()=>[(t.openBlock(),t.createBlock(t.resolveDynamicComponent(e.useActionOutside?"Teleport":"div"),{to:e.useActionOutside?"#kong-ui-app-page-header-action-button":void 0},{default:t.withCtx(()=>[t.createVNode(t.unref(ne),{"auth-function":()=>e.canCreate()},{default:t.withCtx(()=>[t.withDirectives(t.createVNode(j,{appearance:"primary","data-testid":"toolbar-add-credential",icon:"plus",to:e.config.createRoute},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)(`credentials.list.toolbar_actions.${e.config.plugin}.new`)),1)]),_:1},8,["to"]),[[t.vShow,$.value]])]),_:1},8,["auth-function"])]),_:1},8,["to"]))]),group:t.withCtx(({rowValue:h})=>[t.createElementVNode("b",null,t.toDisplayString(h??"-"),1)]),name:t.withCtx(({rowValue:h})=>[t.createElementVNode("b",null,t.toDisplayString(h??"-"),1)]),username:t.withCtx(({rowValue:h})=>[t.createElementVNode("span",null,t.toDisplayString(h??"-"),1)]),password:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:v=>x(v,h,"password"),uuid:k},null,8,["notify","uuid"])]),key:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:v=>x(v,h,"key"),uuid:k},null,8,["notify","uuid"])]),client_secret:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:v=>x(v,h,"client_secret"),uuid:k},null,8,["notify","uuid"])]),secret:t.withCtx(({row:h,rowValue:k})=>[t.createVNode(I,{format:"redacted",notify:v=>x(v,h,"secret"),uuid:k},null,8,["notify","uuid"])]),created_at:t.withCtx(({rowValue:h})=>[t.createTextVNode(t.toDisplayString(t.unref(l)(h)),1)]),tags:t.withCtx(({rowValue:h})=>[(h==null?void 0:h.length)>0?(t.openBlock(),t.createBlock(Kr,{key:0},{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(h,k=>(t.openBlock(),t.createBlock(H,{key:k,onClick:b[0]||(b[0]=t.withModifiers(()=>{},["stop"]))},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(k),1)]),_:2},1024))),128))]),_:2},1024)):(t.openBlock(),t.createElementBlock("span",Br,"-"))]),actions:t.withCtx(({row:h})=>[t.createVNode(q,null,{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(F,{"data-testid":"action-entity-copy-id",onClick:v=>f(h,"id",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_id")),1)]),_:2},1032,["onClick"])]),_:2},1024),e.config.plugin==="basic-auth"?(t.openBlock(),t.createBlock(q,{key:0},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(F,{"data-testid":"action-entity-copy-credential",onClick:v=>f(h,"password",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_credential")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),["key-auth","key-auth-enc","jwt"].includes(e.config.plugin)?(t.openBlock(),t.createBlock(q,{key:1},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(F,{"data-testid":"action-entity-copy-key",onClick:v=>f(h,"key",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_key")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),e.config.plugin==="oauth2"?(t.openBlock(),t.createBlock(q,{key:2},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(F,{"data-testid":"action-entity-copy-secret",onClick:v=>f(h,"client_secret",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_secret")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),e.config.plugin==="hmac-auth"?(t.openBlock(),t.createBlock(q,{key:3},{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(F,{"data-testid":"action-entity-copy-secret",onClick:v=>f(h,"secret",k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_secret")),1)]),_:2},1032,["onClick"])]),_:2},1024)):t.createCommentVNode("",!0),t.createVNode(q,null,{default:t.withCtx(({copyToClipboard:k})=>[t.createVNode(F,{"data-testid":"action-entity-copy-json",onClick:v=>f(h,void 0,k)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.copy_json")),1)]),_:2},1032,["onClick"])]),_:2},1024),t.createVNode(t.unref(ne),{"auth-function":()=>e.canEdit(h)},{default:t.withCtx(()=>[t.createVNode(F,{"data-testid":"action-entity-edit","has-divider":"",item:J(h.id)},null,8,["item"])]),_:2},1032,["auth-function"]),t.createVNode(t.unref(ne),{"auth-function":()=>e.canDelete(h)},{default:t.withCtx(()=>[t.createVNode(F,{danger:"","data-testid":"action-entity-delete","has-divider":"",onClick:k=>D(h)},{default:t.withCtx(()=>[t.createTextVNode(t.toDisplayString(t.unref(i)("credentials.actions.delete")),1)]),_:2},1032,["onClick"])]),_:2},1032,["auth-function"])]),_:1},8,["cache-identifier","empty-state-options","error-message","fetcher","fetcher-cache-key","table-headers","use-action-outside"]),t.createVNode(t.unref(Er),{"action-pending":w.value,description:t.unref(i)("credentials.delete.description"),"entity-type":E.value,error:K.value,title:t.unref(i)(`credentials.delete.${e.config.plugin}.title`),visible:d.value,onCancel:N,onProceed:T},null,8,["action-pending","description","entity-type","error","title","visible"])])}}}),[["__scopeId","data-v-7dc7625b"]]);V.ConsumerCredentialList=$r,Object.defineProperty(V,Symbol.toStringTag,{value:"Module"})});
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .config-card-fieldset[data-v-68ca83ec]{border:solid 1px #e0e4ea;border-radius:4px;margin-bottom:8px;margin-top:4px}.config-card-fieldset-title[data-v-68ca83ec]{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-c96811e5] .k-button.navigation-button{font-size:14px;font-weight:400}.kong-ui-copy-uuid[data-v-0c07874b]{align-items:center;display:flex}.kong-ui-copy-uuid .uuid-container[data-v-0c07874b]{margin-right:12px;white-space:nowrap}.kong-ui-copy-uuid .truncated-uuid[data-v-0c07874b]{margin-right:1ch;max-width:10ch;overflow:hidden;text-overflow:ellipsis}.kong-ui-copy-uuid .uuid-icon-wrapper[data-v-0c07874b]{align-items:center;cursor:pointer;display:flex}.kong-ui-copy-uuid .uuid-icon[data-v-0c07874b]{display:flex}.config-card-details-row[data-v-f65fc52c]{align-items:center;border-bottom:var(--5ae2770e);display:var(--4db3977e);padding:16px 16px 16px 0;width:100%}.config-card-details-row .config-card-details-label[data-v-f65fc52c]{width:var(--1a7c5e02)}.config-card-details-row .config-card-details-label label[data-v-f65fc52c]{color:#3a3f51}.config-card-details-row .config-card-details-value[data-v-f65fc52c]{width:var(--1a77d24c)}.config-card-details-row .config-card-details-value .truncated[data-v-f65fc52c]{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-f65fc52c]{overflow-wrap:anywhere}.config-card-details-row .config-card-details-value .copy-uuid-array[data-v-f65fc52c] .kong-ui-copy-uuid:not(:last-of-type){margin-bottom:8px}.config-card-details-row .config-card-details-value .method-badge-array[data-v-f65fc52c]{display:flex;flex-wrap:wrap;row-gap:10px}.config-card-details-row .config-badge[data-v-f65fc52c]{margin-right:4px}.config-card-details-row[data-v-f65fc52c] .k-label{margin-bottom:0}.config-card-details-row[data-v-f65fc52c] .k-label .kong-icon-infoFilled{display:flex}.config-card-details-row[data-v-f65fc52c] .config-card-details-row{width:auto}.json-config #json-endpoint-codeblock .k-highlighted-code-block code,.json-config #json-codeblock .k-highlighted-code-block code{background-color:#232633}.json-config #json-endpoint-codeblock .k-code-block-secondary-actions,.json-config #json-codeblock .k-code-block-secondary-actions{top:12px!important}.json-content .k-highlighted-code-block{border-top-left-radius:0!important;border-top-right-radius:0!important}.json-endpoint{align-items:baseline;background-color:#232633;border-bottom:1px solid rgba(255,255,255,.24);border-top-left-radius:8px;border-top-right-radius:8px;display:flex;padding-left:12px}.json-endpoint .k-badge{height:24px}.json-endpoint .k-code-block{flex:auto}.json-endpoint code{direction:rtl;max-width:var(--2d178975);overflow:hidden!important;text-align:left;text-overflow:ellipsis;white-space:nowrap}.yaml-config #yaml-codeblock .k-highlighted-code-block code{background-color:#232633}.yaml-config #yaml-codeblock .k-code-block-secondary-actions{top:12px!important}.config-card-prop-section-title[data-v-2b74ac63]{color:#000933;font-size:16px;font-weight:600;margin-bottom:16px;margin-top:48px}.kong-ui-entity-base-config-card .k-card-title[data-v-3fd4a3a4]{margin-bottom:0}.kong-ui-entity-base-config-card[data-v-3fd4a3a4] .k-card-content .k-card-body{font-size:14px}.kong-ui-entity-base-config-card .config-card-actions[data-v-3fd4a3a4]{align-items:center;display:flex}.kong-ui-entity-base-config-card .config-card-actions .config-format-select-label[data-v-3fd4a3a4]{margin-bottom:0;margin-right:8px}.kong-ui-entity-base-config-card .config-card-prop-section-title[data-v-3fd4a3a4]{color:#000933;font-size:16px;font-weight:600;margin-bottom:16px;margin-top:48px}.kong-ui-entity-base-config-card[data-v-3fd4a3a4] .config-card-details-row:last-of-type{border-bottom:none}.kong-ui-entity-base-config-card .book-icon[data-v-3fd4a3a4]{margin-left:8px;padding:0}.kong-ui-entity-base-form[data-v-736c9e55]{box-sizing:border-box;max-width:1536px;width:100%}.kong-ui-entity-base-form .form-actions[data-v-736c9e55]{align-items:center;display:flex;justify-content:flex-end;margin-top:24px}.kong-ui-entity-base-form .form-actions[data-v-736c9e55] .k-button:last-of-type,.kong-ui-entity-base-form .form-actions[data-v-736c9e55] .k-button:nth-last-of-type(2){margin-left:16px}.kong-ui-entity-base-form[data-v-736c9e55] .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-736c9e55] .k-card.content-card{padding:0 16px!important}.kong-ui-entity-base-form[data-v-736c9e55] .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-736c9e55] .tab-item.active>div.tab-link.has-panels{color:#000933!important;font-weight:600!important}.content-wrapper[data-v-c4379fd4] [role=button]{display:inline}.content-wrapper[data-v-c4379fd4] .k-tooltip{word-break:break-all}.kong-ui-entity-base-table .toolbar-container[data-v-ecfaa7cf]{align-items:center}.kong-ui-entity-base-table .toolbar-button-container[data-v-ecfaa7cf]{margin-left:auto}.kong-ui-entity-base-table .actions-container[data-v-ecfaa7cf]{float:right}.kong-ui-entity-base-table .actions-container[data-v-ecfaa7cf] .k-dropdown-item-trigger{margin-bottom:0;margin-top:0}.kong-ui-entity-base-table .actions-trigger[data-v-ecfaa7cf]{background-color:#0000!important;border:none!important;cursor:pointer!important;font-weight:400!important}.kong-ui-entity-base-table :deep(.k-table){table-layout:fixed}.kong-ui-entity-delete-modal .message[data-v-efe8f34b],.kong-ui-entity-delete-modal .description[data-v-efe8f34b]{line-height:24px;margin:0}.kong-ui-entity-delete-modal .message strong[data-v-efe8f34b]{font-weight:600}.kong-ui-entity-delete-modal .description[data-v-efe8f34b]{margin-top:32px}.kong-ui-entity-delete-error[data-v-efe8f34b]{margin-bottom:16px}.kong-ui-entity-filter-input[data-v-e9512e8f]{width:100%}.kong-ui-entity-filter[data-v-e9512e8f]{display:flex;position:relative}.kong-ui-entity-filter[data-v-e9512e8f] .menu-content{flex-direction:column}.kong-ui-entity-filter[data-v-e9512e8f] .k-menu-item-divider hr{margin:12px 0}.kong-ui-entity-filter-backdrop[data-v-e9512e8f]{bottom:0;left:0;position:fixed;right:0;top:0;z-index:1050}.kong-ui-entity-filter-menu[data-v-e9512e8f]{box-shadow:0 4px 20px #e0e4ea;left:0;margin-top:16px;position:absolute;top:100%;z-index:1060}.kong-ui-entity-filter-menu[data-v-e9512e8f] .k-menu-item .menu-button:focus{box-shadow:none}.kong-ui-entity-filter-menu[data-v-e9512e8f] .k-menu-item .menu-button:focus-visible{box-shadow:0 0 0 1px #bee2ff}.menu-item-title[data-v-e9512e8f]{align-items:center;display:flex}.menu-item-indicator[data-v-e9512e8f]{background-color:#0044f4;border-radius:50%;height:4px;margin-left:4px;width:4px}.menu-item-body[data-v-e9512e8f]{align-items:center;display:flex;justify-content:space-between}.menu-item-body[data-v-e9512e8f] .k-input{padding-bottom:4px!important;padding-top:4px!important}.menu-item-body[data-v-e9512e8f] .k-input-wrapper{width:100%}.menu-item-body[data-v-e9512e8f] .k-select-input .k-input{font-size:12px}.menu-item-body[data-v-e9512e8f] .k-select-input .k-input::placeholder{color:#00000073!important;font-size:12px}.menu-item-label[data-v-e9512e8f]{margin-bottom:0;margin-right:12px}.menu-item-buttons[data-v-e9512e8f]{display:flex;justify-content:space-between;margin:10px 0 6px}.filter-clear-button-container[data-v-e9512e8f]{padding:0 20px}fieldset[data-v-3565daa7]{margin:0;padding:0}.kong-ui-entity-form-section[data-v-3565daa7]{border:0}.kong-ui-entity-form-section .form-section-wrapper[data-v-3565daa7]{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-3565daa7]{flex-direction:row}}.kong-ui-entity-form-section .form-section-wrapper .form-section-info[data-v-3565daa7]{flex:1}@media (min-width: 1024px){.kong-ui-entity-form-section .form-section-wrapper .form-section-info[data-v-3565daa7]{max-width:350px}.kong-ui-entity-form-section .form-section-wrapper .form-section-info.sticky[data-v-3565daa7]{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-3565daa7]{color:#000933;font-size:18px;font-weight:600;line-height:24px;margin-bottom:8px;margin-top:0}.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description[data-v-3565daa7],.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description p[data-v-3565daa7],.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description[data-v-3565daa7] 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-3565daa7]{margin-top:32px}.kong-ui-entity-form-section .form-section-wrapper .form-section-content[data-v-3565daa7]{flex:1}.kong-ui-entity-form-section .form-section-wrapper .form-section-content[data-v-3565daa7]>*:not(:first-child){margin-top:24px}.kong-ui-entity-form-section.has-divider .form-section-wrapper[data-v-3565daa7]{border-bottom:1px solid #e0e4ea}.kong-ui-public-entity-link[data-v-ff8e5179]{align-items:center;display:flex}.kong-ui-public-entity-link .deleted-entity[data-v-ff8e5179]{font-style:italic}.kong-ui-public-entity-link .entity-link[data-v-ff8e5179]{display:flex}.kong-ui-public-entity-link .entity-link[data-v-ff8e5179] .external-link-icon{color:#0044f4;margin-left:4px;padding:2px}.kong-ui-public-entity-link .entity-link-label[data-v-ff8e5179]{display:inline-block;font-weight:400;max-width:20ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kong-ui-public-entity-link .copy-uuid-tooltip[data-v-ff8e5179]{align-items:center;cursor:pointer;display:flex}.kong-ui-public-entity-link .copy-uuid-tooltip .entity-link-copy-id[data-v-ff8e5179]{margin-left:2px}.kong-ui-entities-consumer-credentials-list[data-v-6e469a8e]{width:100%}
1
+ .config-card-fieldset[data-v-68ca83ec]{border:solid 1px #e0e4ea;border-radius:4px;margin-bottom:8px;margin-top:4px}.config-card-fieldset-title[data-v-68ca83ec]{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-c96811e5] .k-button.navigation-button{font-size:14px;font-weight:400}.kong-ui-copy-uuid[data-v-0c07874b]{align-items:center;display:flex}.kong-ui-copy-uuid .uuid-container[data-v-0c07874b]{margin-right:12px;white-space:nowrap}.kong-ui-copy-uuid .truncated-uuid[data-v-0c07874b]{margin-right:1ch;max-width:10ch;overflow:hidden;text-overflow:ellipsis}.kong-ui-copy-uuid .uuid-icon-wrapper[data-v-0c07874b]{align-items:center;cursor:pointer;display:flex}.kong-ui-copy-uuid .uuid-icon[data-v-0c07874b]{display:flex}.config-card-details-row[data-v-f65fc52c]{align-items:center;border-bottom:var(--5ae2770e);display:var(--4db3977e);padding:16px 16px 16px 0;width:100%}.config-card-details-row .config-card-details-label[data-v-f65fc52c]{width:var(--1a7c5e02)}.config-card-details-row .config-card-details-label label[data-v-f65fc52c]{color:#3a3f51}.config-card-details-row .config-card-details-value[data-v-f65fc52c]{width:var(--1a77d24c)}.config-card-details-row .config-card-details-value .truncated[data-v-f65fc52c]{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-f65fc52c]{overflow-wrap:anywhere}.config-card-details-row .config-card-details-value .copy-uuid-array[data-v-f65fc52c] .kong-ui-copy-uuid:not(:last-of-type){margin-bottom:8px}.config-card-details-row .config-card-details-value .method-badge-array[data-v-f65fc52c]{display:flex;flex-wrap:wrap;row-gap:10px}.config-card-details-row .config-badge[data-v-f65fc52c]{margin-right:4px}.config-card-details-row[data-v-f65fc52c] .k-label{margin-bottom:0}.config-card-details-row[data-v-f65fc52c] .k-label .kong-icon-infoFilled{display:flex}.config-card-details-row[data-v-f65fc52c] .config-card-details-row{width:auto}.json-config #json-endpoint-codeblock .k-highlighted-code-block code,.json-config #json-codeblock .k-highlighted-code-block code{background-color:#232633}.json-config #json-endpoint-codeblock .k-code-block-secondary-actions,.json-config #json-codeblock .k-code-block-secondary-actions{top:12px!important}.json-content .k-highlighted-code-block{border-top-left-radius:0!important;border-top-right-radius:0!important}.json-endpoint{align-items:baseline;background-color:#232633;border-bottom:1px solid rgba(255,255,255,.24);border-top-left-radius:8px;border-top-right-radius:8px;display:flex;padding-left:12px}.json-endpoint .k-badge{height:24px}.json-endpoint .k-code-block{flex:auto}.json-endpoint code{direction:rtl;max-width:var(--2d178975);overflow:hidden!important;text-align:left;text-overflow:ellipsis;white-space:nowrap}.yaml-config #yaml-codeblock .k-highlighted-code-block code{background-color:#232633}.yaml-config #yaml-codeblock .k-code-block-secondary-actions{top:12px!important}.config-card-prop-section-title[data-v-2b74ac63]{color:#000933;font-size:16px;font-weight:600;margin-bottom:16px;margin-top:48px}.kong-ui-entity-base-config-card .k-card-title[data-v-3fd4a3a4]{margin-bottom:0}.kong-ui-entity-base-config-card[data-v-3fd4a3a4] .k-card-content .k-card-body{font-size:14px}.kong-ui-entity-base-config-card .config-card-actions[data-v-3fd4a3a4]{align-items:center;display:flex}.kong-ui-entity-base-config-card .config-card-actions .config-format-select-label[data-v-3fd4a3a4]{margin-bottom:0;margin-right:8px}.kong-ui-entity-base-config-card .config-card-prop-section-title[data-v-3fd4a3a4]{color:#000933;font-size:16px;font-weight:600;margin-bottom:16px;margin-top:48px}.kong-ui-entity-base-config-card[data-v-3fd4a3a4] .config-card-details-row:last-of-type{border-bottom:none}.kong-ui-entity-base-config-card .book-icon[data-v-3fd4a3a4]{margin-left:8px;padding:0}.kong-ui-entity-base-form[data-v-736c9e55]{box-sizing:border-box;max-width:1536px;width:100%}.kong-ui-entity-base-form .form-actions[data-v-736c9e55]{align-items:center;display:flex;justify-content:flex-end;margin-top:24px}.kong-ui-entity-base-form .form-actions[data-v-736c9e55] .k-button:last-of-type,.kong-ui-entity-base-form .form-actions[data-v-736c9e55] .k-button:nth-last-of-type(2){margin-left:16px}.kong-ui-entity-base-form[data-v-736c9e55] .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-736c9e55] .k-card.content-card{padding:0 16px!important}.kong-ui-entity-base-form[data-v-736c9e55] .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-736c9e55] .tab-item.active>div.tab-link.has-panels{color:#000933!important;font-weight:600!important}.content-wrapper[data-v-c4379fd4] [role=button]{display:inline}.content-wrapper[data-v-c4379fd4] .k-tooltip{word-break:break-all}.kong-ui-entity-base-table .toolbar-container[data-v-ecfaa7cf]{align-items:center}.kong-ui-entity-base-table .toolbar-button-container[data-v-ecfaa7cf]{margin-left:auto}.kong-ui-entity-base-table .actions-container[data-v-ecfaa7cf]{float:right}.kong-ui-entity-base-table .actions-container[data-v-ecfaa7cf] .k-dropdown-item-trigger{margin-bottom:0;margin-top:0}.kong-ui-entity-base-table .actions-trigger[data-v-ecfaa7cf]{background-color:#0000!important;border:none!important;cursor:pointer!important;font-weight:400!important}.kong-ui-entity-base-table :deep(.k-table){table-layout:fixed}.kong-ui-entity-delete-modal .message[data-v-efe8f34b],.kong-ui-entity-delete-modal .description[data-v-efe8f34b]{line-height:24px;margin:0}.kong-ui-entity-delete-modal .message strong[data-v-efe8f34b]{font-weight:600}.kong-ui-entity-delete-modal .description[data-v-efe8f34b]{margin-top:32px}.kong-ui-entity-delete-error[data-v-efe8f34b]{margin-bottom:16px}.kong-ui-entity-filter-input[data-v-e9512e8f]{width:100%}.kong-ui-entity-filter[data-v-e9512e8f]{display:flex;position:relative}.kong-ui-entity-filter[data-v-e9512e8f] .menu-content{flex-direction:column}.kong-ui-entity-filter[data-v-e9512e8f] .k-menu-item-divider hr{margin:12px 0}.kong-ui-entity-filter-backdrop[data-v-e9512e8f]{bottom:0;left:0;position:fixed;right:0;top:0;z-index:1050}.kong-ui-entity-filter-menu[data-v-e9512e8f]{box-shadow:0 4px 20px #e0e4ea;left:0;margin-top:16px;position:absolute;top:100%;z-index:1060}.kong-ui-entity-filter-menu[data-v-e9512e8f] .k-menu-item .menu-button:focus{box-shadow:none}.kong-ui-entity-filter-menu[data-v-e9512e8f] .k-menu-item .menu-button:focus-visible{box-shadow:0 0 0 1px #bee2ff}.menu-item-title[data-v-e9512e8f]{align-items:center;display:flex}.menu-item-indicator[data-v-e9512e8f]{background-color:#0044f4;border-radius:50%;height:4px;margin-left:4px;width:4px}.menu-item-body[data-v-e9512e8f]{align-items:center;display:flex;justify-content:space-between}.menu-item-body[data-v-e9512e8f] .k-input{padding-bottom:4px!important;padding-top:4px!important}.menu-item-body[data-v-e9512e8f] .k-input-wrapper{width:100%}.menu-item-body[data-v-e9512e8f] .k-select-input .k-input{font-size:12px}.menu-item-body[data-v-e9512e8f] .k-select-input .k-input::placeholder{color:#00000073!important;font-size:12px}.menu-item-label[data-v-e9512e8f]{margin-bottom:0;margin-right:12px}.menu-item-buttons[data-v-e9512e8f]{display:flex;justify-content:space-between;margin:10px 0 6px}.filter-clear-button-container[data-v-e9512e8f]{padding:0 20px}fieldset[data-v-3565daa7]{margin:0;padding:0}.kong-ui-entity-form-section[data-v-3565daa7]{border:0}.kong-ui-entity-form-section .form-section-wrapper[data-v-3565daa7]{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-3565daa7]{flex-direction:row}}.kong-ui-entity-form-section .form-section-wrapper .form-section-info[data-v-3565daa7]{flex:1}@media (min-width: 1024px){.kong-ui-entity-form-section .form-section-wrapper .form-section-info[data-v-3565daa7]{max-width:350px}.kong-ui-entity-form-section .form-section-wrapper .form-section-info.sticky[data-v-3565daa7]{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-3565daa7]{color:#000933;font-size:18px;font-weight:600;line-height:24px;margin-bottom:8px;margin-top:0}.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description[data-v-3565daa7],.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description p[data-v-3565daa7],.kong-ui-entity-form-section .form-section-wrapper .form-section-info .form-section-description[data-v-3565daa7] 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-3565daa7]{margin-top:32px}.kong-ui-entity-form-section .form-section-wrapper .form-section-content[data-v-3565daa7]{flex:1}.kong-ui-entity-form-section .form-section-wrapper .form-section-content[data-v-3565daa7]>*:not(:first-child){margin-top:24px}.kong-ui-entity-form-section.has-divider .form-section-wrapper[data-v-3565daa7]{border-bottom:1px solid #e0e4ea}.kong-ui-public-entity-link[data-v-ff8e5179]{align-items:center;display:flex}.kong-ui-public-entity-link .deleted-entity[data-v-ff8e5179]{font-style:italic}.kong-ui-public-entity-link .entity-link[data-v-ff8e5179]{display:flex}.kong-ui-public-entity-link .entity-link[data-v-ff8e5179] .external-link-icon{color:#0044f4;margin-left:4px;padding:2px}.kong-ui-public-entity-link .entity-link-label[data-v-ff8e5179]{display:inline-block;font-weight:400;max-width:20ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.kong-ui-public-entity-link .copy-uuid-tooltip[data-v-ff8e5179]{align-items:center;cursor:pointer;display:flex}.kong-ui-public-entity-link .copy-uuid-tooltip .entity-link-copy-id[data-v-ff8e5179]{margin-left:2px}.kong-ui-entities-consumer-credentials-list[data-v-7dc7625b]{width:100%}
@@ -1 +1 @@
1
- {"version":3,"file":"ConsumerCredentialList.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ConsumerCredentialList.vue.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAEnC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAcvC,OAAO,KAAK,EAEV,uCAAuC,EACvC,mCAAmC,EACnC,SAAS,EACT,gBAAgB,EACjB,MAAM,UAAU,CAAA;AAMjB,OAAO,gDAAgD,CAAA;;IAi+BrD,oHAAoH;;;;4BAI9F,mCAAmC,GAAG,uCAAuC,KAAG,OAAO;;;;;;IAW7G,yHAAyH;;6BAEtF,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI7D,2HAA2H;;6BAExF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,yHAAyH;;6BAEtF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,iHAAiH;;;;;;;;;;;IAjCjH,oHAAoH;;;;4BAI9F,mCAAmC,GAAG,uCAAuC,KAAG,OAAO;;;;;;IAW7G,yHAAyH;;6BAEtF,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI7D,2HAA2H;;6BAExF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,yHAAyH;;6BAEtF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,iHAAiH;;;;;;;;;;;;qBAhB9E,OAAO,GAAG,QAAQ,OAAO,CAAC;qBAM1B,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;mBAMxC,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;AAnC7E,wBA8CG"}
1
+ {"version":3,"file":"ConsumerCredentialList.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ConsumerCredentialList.vue.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,KAAK,CAAA;AAEnC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAcvC,OAAO,KAAK,EAEV,uCAAuC,EACvC,mCAAmC,EACnC,SAAS,EACT,gBAAgB,EACjB,MAAM,UAAU,CAAA;AAMjB,OAAO,gDAAgD,CAAA;;IAo+BrD,oHAAoH;;;;4BAI9F,mCAAmC,GAAG,uCAAuC,KAAG,OAAO;;;;;;IAW7G,yHAAyH;;6BAEtF,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI7D,2HAA2H;;6BAExF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,yHAAyH;;6BAEtF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,iHAAiH;;;;;;;;;;;IAjCjH,oHAAoH;;;;4BAI9F,mCAAmC,GAAG,uCAAuC,KAAG,OAAO;;;;;;IAW7G,yHAAyH;;6BAEtF,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI7D,2HAA2H;;6BAExF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,yHAAyH;;6BAEtF,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;;IAI3E,iHAAiH;;;;;;;;;;;;qBAhB9E,OAAO,GAAG,QAAQ,OAAO,CAAC;qBAM1B,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;mBAMxC,SAAS,KAAK,OAAO,GAAG,QAAQ,OAAO,CAAC;;;AAnC7E,wBA8CG"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kong-ui-public/entities-consumer-credentials",
3
- "version": "2.1.59",
3
+ "version": "2.1.60",
4
4
  "type": "module",
5
5
  "main": "./dist/entities-consumer-credentials.umd.js",
6
6
  "module": "./dist/entities-consumer-credentials.es.js",
@@ -34,8 +34,8 @@
34
34
  "axios": "^1.6.7",
35
35
  "vue": "^3.4.19",
36
36
  "vue-router": "^4.2.5",
37
- "@kong-ui-public/i18n": "^2.1.3",
38
- "@kong-ui-public/copy-uuid": "^2.0.40"
37
+ "@kong-ui-public/copy-uuid": "^2.0.40",
38
+ "@kong-ui-public/i18n": "^2.1.3"
39
39
  },
40
40
  "repository": {
41
41
  "type": "git",