@kong-ui-public/entities-gateway-services 3.10.4-pr.1990.f7a2d582d.0 → 3.10.4-pr.2001.6ea4ed63c.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +1,9 @@
1
- import { defineComponent as Ee, computed as b, ref as P, watch as Te, onBeforeMount as Be, resolveComponent as F, openBlock as I, createElementBlock as K, createVNode as d, unref as l, createSlots as Le, withCtx as f, createBlock as fe, Teleport as Pe, createElementVNode as C, createCommentVNode as L, createTextVNode as M, toDisplayString as h, withModifiers as Ie, reactive as Ue, onMounted as De, renderSlot as Ge } from "vue";
2
- import { useRouter as $e } from "vue-router";
3
- import { BookIcon as Ke, AddIcon as qe, ServicesIcon as Oe } from "@kong/icons";
4
- import { createI18n as Ne, i18nTComponent as We } from "@kong-ui-public/i18n";
5
- import { AppType as g, useAxios as xe, useTableState as je, useFetcher as He, useDeleteUrlBuilder as ze, FetcherStatus as Je, EntityBaseTable as Qe, EntityFilter as Xe, PermissionsWrapper as se, TableTags as Ze, EntityEmptyState as Ye, EntityToggleModal as et, EntityDeleteModal as tt, EntityTypes as lt, useErrors as ot, useValidators as it, EntityBaseFormType as Re, useGatewayFeatureSupported as st, EntityBaseForm as rt, SupportedEntityType as Ae, EntityFormSection as Me, useHelpers as at, ConfigurationSchemaSection as pe, ConfigurationSchemaType as nt, EntityBaseConfigCard as ct } from "@kong-ui-public/entities-shared";
6
- const dt = {
1
+ import { defineComponent as Re, computed as h, ref as R, watch as Ue, onBeforeMount as je, resolveComponent as $, openBlock as w, createElementBlock as T, createVNode as d, unref as o, createSlots as ze, withCtx as u, createBlock as se, Teleport as xe, createElementVNode as E, createCommentVNode as x, createTextVNode as K, toDisplayString as I, withModifiers as Te, toValue as $e, reactive as Me, onMounted as Ze, renderSlot as He, Transition as Ae, Fragment as Je, renderList as Qe } from "vue";
2
+ import { useRouter as Ne } from "vue-router";
3
+ import { BookIcon as Be, AddIcon as Xe, ServicesIcon as Ye } from "@kong/icons";
4
+ import { createI18n as et, i18nTComponent as tt } from "@kong-ui-public/i18n";
5
+ import { useAxios as qe, useTableState as ot, useFetcher as it, useDeleteUrlBuilder as lt, FetcherStatus as rt, EntityBaseTable as st, EntityFilter as at, PermissionsWrapper as re, TableTags as nt, EntityEmptyState as ct, EntityToggleModal as dt, EntityDeleteModal as ut, EntityTypes as ft, useErrors as pt, useValidators as mt, EntityBaseFormType as De, useGatewayFeatureSupported as vt, EntityBaseForm as gt, SupportedEntityType as We, EntityFormSection as Le, useHelpers as yt, ConfigurationSchemaSection as be, ConfigurationSchemaType as _t, EntityBaseConfigCard as ht } from "@kong-ui-public/entities-shared";
6
+ const bt = {
7
7
  create: "New gateway service",
8
8
  serverless_create: "Add a Service",
9
9
  copy_id: "Copy ID",
@@ -16,12 +16,12 @@ const dt = {
16
16
  description: "Deleting this Gateway Service will also remove any associated plugins. This action cannot be reversed.",
17
17
  menu_label: "Delete"
18
18
  }
19
- }, ut = {
19
+ }, wt = {
20
20
  placeholder: {
21
21
  konnect: "Filter by name",
22
22
  kongManager: "Filter by exact name or ID"
23
23
  }
24
- }, ft = {
24
+ }, kt = {
25
25
  title: "Gateway Services",
26
26
  list: {
27
27
  toolbar_actions: {
@@ -55,21 +55,27 @@ const dt = {
55
55
  sections: {
56
56
  general: {
57
57
  title: "General Information",
58
- description: "General information will help identify and manage this Gateway Service."
58
+ description: "Provide a name and tags to help identify and manage this service."
59
59
  },
60
60
  keys: {
61
61
  title: "Service Endpoint",
62
- description: "Define the endpoint for this service by specifying the full URL or by its separate elements.",
62
+ description: "Define where this service should send requests.",
63
63
  checkedGroupLabel: "Choose how and where to send traffic",
64
- urlLabel: "Full URL",
65
- checkedGroupAltLabel: "Protocol, Host, Port and Path",
64
+ url: {
65
+ label: "Full URL",
66
+ description: "Define the service using a single, complete API URL for simple setup."
67
+ },
68
+ protocol: {
69
+ label: "Protocol, host, port, and path",
70
+ description: "Manually specify each component of the API’s URL for advanced configurations."
71
+ },
66
72
  viewAdvancedFields: "View Advanced Fields"
67
73
  }
68
74
  },
69
75
  fields: {
70
76
  upstream_url: {
71
- label: "Upstream URL",
72
- placeholder: "Enter a URL",
77
+ label: "Full URL",
78
+ placeholder: "e.g. https://www.myapi.com/",
73
79
  tooltip_for_konnect: "This is the URL of the API you will manage in Konnect.",
74
80
  tooltip_for_km: "This is the URL of the API you will manage in Kong Gateway."
75
81
  },
@@ -159,7 +165,8 @@ const dt = {
159
165
  label: "Tags",
160
166
  tooltip: "An optional set of strings associated with the Service for grouping and filtering.",
161
167
  placeholder: "Enter a list of tags separated by comma",
162
- help: "e.g. tag1, tag2, tag3"
168
+ help: "e.g. tag1, tag2, tag3",
169
+ collapse: "Add tags"
163
170
  },
164
171
  enabled: {
165
172
  label: "Enabled",
@@ -169,39 +176,39 @@ const dt = {
169
176
  }
170
177
  }
171
178
  }
172
- }, pt = {
179
+ }, Ct = {
173
180
  general: "Gateway Services could not be retrieved",
174
181
  delete: "The gateway service could not be deleted at this time.",
175
182
  copy: "Failed to copy to clipboard",
176
183
  urlErrorMessage: "Error: invalid URL"
177
- }, mt = {
184
+ }, Vt = {
178
185
  success: "Copied {val} to clipboard",
179
186
  success_brief: "Successfully copied to clipboard"
180
- }, vt = {
187
+ }, St = {
181
188
  gateway_services: "gateway services"
182
- }, yt = {
183
- actions: dt,
184
- search: ut,
185
- gateway_services: ft,
186
- errors: pt,
187
- copy: mt,
188
- glossary: vt
189
+ }, Et = {
190
+ actions: bt,
191
+ search: wt,
192
+ gateway_services: kt,
193
+ errors: Ct,
194
+ copy: Vt,
195
+ glossary: St
189
196
  };
190
- function gt() {
191
- const n = Ne("en-us", yt);
197
+ function It() {
198
+ const a = et("en-us", Et);
192
199
  return {
193
- i18n: n,
194
- i18nT: We(n)
200
+ i18n: a,
201
+ i18nT: tt(a)
195
202
  // Translation component <i18n-t>
196
203
  };
197
204
  }
198
- function _t() {
205
+ function Ft() {
199
206
  return {
200
- getPortFromProtocol: (D, p) => {
201
- const c = [80, 443], r = Number(p);
202
- if ((r || r === 0) && !c.includes(r))
207
+ getPortFromProtocol: (P, p) => {
208
+ const n = [80, 443], r = Number(p);
209
+ if ((r || r === 0) && !n.includes(r))
203
210
  return r;
204
- switch (D) {
211
+ switch (P) {
205
212
  case "grpcs":
206
213
  case "tls":
207
214
  case "https":
@@ -217,38 +224,38 @@ function _t() {
217
224
  }
218
225
  };
219
226
  }
220
- const ye = {
221
- useI18n: gt,
222
- usePortFromProtocol: _t
223
- }, me = "/v2/control-planes/{controlPlaneId}/core-entities", ve = "/{workspace}", re = {
227
+ const Ce = {
228
+ useI18n: It,
229
+ usePortFromProtocol: Ft
230
+ }, we = "/v2/control-planes/{controlPlaneId}/core-entities", ke = "/{workspace}", ae = {
224
231
  list: {
225
232
  konnect: {
226
- all: `${me}/services`
233
+ all: `${we}/services`
227
234
  },
228
235
  kongManager: {
229
- all: `${ve}/services`
236
+ all: `${ke}/services`
230
237
  }
231
238
  },
232
239
  form: {
233
240
  konnect: {
234
- create: `${me}/services`,
235
- validate: `${me}/v1/schemas/json/service/validate`,
236
- edit: `${me}/services/{id}`
241
+ create: `${we}/services`,
242
+ validate: `${we}/v1/schemas/json/service/validate`,
243
+ edit: `${we}/services/{id}`
237
244
  },
238
245
  kongManager: {
239
- create: `${ve}/services`,
240
- validate: `${ve}/schemas/services/validate`,
241
- edit: `${ve}/services/{id}`
246
+ create: `${ke}/services`,
247
+ validate: `${ke}/schemas/services/validate`,
248
+ edit: `${ke}/services/{id}`
242
249
  }
243
250
  }
244
- }, bt = "#00abd2", ht = "24px", wt = { class: "kong-ui-entities-gateway-services-list" }, kt = { class: "button-row" }, Ct = { class: "empty-state-icon-gateway" }, Vt = { key: 1 }, St = /* @__PURE__ */ Ee({
251
+ }, Pt = "#00abd2", Tt = "24px", At = { class: "kong-ui-entities-gateway-services-list" }, Ut = { class: "button-row" }, Rt = { class: "empty-state-icon-gateway" }, xt = { key: 1 }, $t = /* @__PURE__ */ Re({
245
252
  __name: "GatewayServiceList",
246
253
  props: {
247
254
  /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
248
255
  config: {
249
256
  type: Object,
250
257
  required: !0,
251
- validator: (n) => !(!n || ![g.Konnect, g.KongManager].includes(n == null ? void 0 : n.app) || !n.createRoute || !n.getViewRoute || !n.getEditRoute || n.app === g.KongManager && !n.isExactMatch && !n.filterSchema)
258
+ validator: (a) => !(!a || !["konnect", "kongManager"].includes(a == null ? void 0 : a.app) || !a.createRoute || !a.getViewRoute || !a.getEditRoute || a.app === "kongManager" && !a.isExactMatch && !a.filterSchema)
252
259
  },
253
260
  // used to override the default identifier for the cache entry
254
261
  cacheIdentifier: {
@@ -299,12 +306,12 @@ const ye = {
299
306
  }
300
307
  },
301
308
  emits: ["error", "click:learn-more", "copy:success", "copy:error", "delete:success", "toggle:success"],
302
- setup(n, { emit: D }) {
303
- var o;
304
- const p = D, c = n, { i18n: { t: r, formatUnixTimeStamp: $ } } = ye.useI18n(), W = $e(), { axiosInstance: O } = xe((o = c.config) == null ? void 0 : o.axiosRequestConfig), { hasRecords: a, handleStateChange: U } = je(() => G.value), V = b(() => a.value && c.config.app === g.Konnect), ge = b(() => !c.enableV2EmptyStates && c.config.app === g.Konnect), _e = b(() => c.config.app !== g.KongManager || !!c.config.disableSorting), N = {
309
+ setup(a, { emit: P }) {
310
+ var he;
311
+ const p = P, n = a, { i18n: { t: r, formatUnixTimeStamp: C } } = Ce.useI18n(), B = Ne(), { axiosInstance: O } = qe((he = n.config) == null ? void 0 : he.axiosRequestConfig), { hasRecords: s, handleStateChange: A } = ot(() => N.value), k = h(() => s.value && n.config.app === "konnect"), D = h(() => !n.enableV2EmptyStates && n.config.app === "konnect"), Q = h(() => n.config.app !== "kongManager" || !!n.config.disableSorting), ne = {
305
312
  // the Name column is non-hidable
306
313
  name: { label: r("gateway_services.list.table_headers.name"), searchable: !0, sortable: !0, hidable: !1 },
307
- ...c.config.showControlPlaneColumn ? { control_plane: { label: r("gateway_services.list.table_headers.control_plane") } } : {},
314
+ ...n.config.showControlPlaneColumn ? { control_plane: { label: r("gateway_services.list.table_headers.control_plane") } } : {},
308
315
  protocol: { label: r("gateway_services.list.table_headers.protocol"), searchable: !0, sortable: !0 },
309
316
  host: { label: r("gateway_services.list.table_headers.host"), searchable: !0, sortable: !0 },
310
317
  port: { label: r("gateway_services.list.table_headers.port"), searchable: !0, sortable: !0 },
@@ -313,197 +320,197 @@ const ye = {
313
320
  tags: { label: r("gateway_services.list.table_headers.tags"), sortable: !1 },
314
321
  updated_at: { label: r("gateway_services.list.table_headers.updated_at"), sortable: !0 },
315
322
  created_at: { label: r("gateway_services.list.table_headers.created_at"), sortable: !0 }
316
- }, be = {
323
+ }, G = {
317
324
  columnVisibility: {
318
325
  created_at: !1
319
326
  }
320
- }, z = N, _ = b(() => {
321
- var s, y;
322
- let u = `${c.config.apiBaseUrl}${re.list[c.config.app].all}`;
323
- return c.config.app === g.Konnect ? u = u.replace(/{controlPlaneId}/gi, ((s = c.config) == null ? void 0 : s.controlPlaneId) || "") : c.config.app === g.KongManager && (u = u.replace(/\/{workspace}/gi, (y = c.config) != null && y.workspace ? `/${c.config.workspace}` : "")), u;
324
- }), ee = b(() => c.config.apiBaseUrl.startsWith("/") ? new URL(`${window.location.origin}${_.value}`) : new URL(_.value)), G = P(""), he = b(() => {
325
- const u = c.config.app === g.Konnect || c.config.isExactMatch;
326
- if (u)
327
+ }, Ve = ne, L = h(() => {
328
+ var v, g;
329
+ let f = `${n.config.apiBaseUrl}${ae.list[n.config.app].all}`;
330
+ return n.config.app === "konnect" ? f = f.replace(/{controlPlaneId}/gi, ((v = n.config) == null ? void 0 : v.controlPlaneId) || "") : n.config.app === "kongManager" && (f = f.replace(/\/{workspace}/gi, (g = n.config) != null && g.workspace ? `/${n.config.workspace}` : "")), f;
331
+ }), F = h(() => n.config.apiBaseUrl.startsWith("/") ? new URL(`${window.location.origin}${L.value}`) : new URL(L.value)), N = R(""), X = h(() => {
332
+ const f = n.config.app === "konnect" || n.config.isExactMatch;
333
+ if (f)
327
334
  return {
328
- isExactMatch: u,
329
- placeholder: r(`search.placeholder.${c.config.app}`)
335
+ isExactMatch: f,
336
+ placeholder: r(`search.placeholder.${n.config.app}`)
330
337
  };
331
- const { name: s, enabled: y, protocol: T, host: Y, port: x, path: ue } = N;
338
+ const { name: v, enabled: g, protocol: V, host: W, port: e, path: i } = ne;
332
339
  return {
333
- isExactMatch: u,
334
- fields: { name: s, enabled: y, protocol: T, host: Y, port: x, path: ue },
335
- schema: c.config.filterSchema
340
+ isExactMatch: f,
341
+ fields: { name: v, enabled: g, protocol: V, host: W, port: e, path: i },
342
+ schema: n.config.filterSchema
336
343
  };
337
344
  }), {
338
- fetcher: e,
339
- fetcherState: k,
340
- fetcherCacheKey: te
341
- } = He({ ...c.config, cacheIdentifier: c.cacheIdentifier }, _.value), we = () => {
342
- G.value = "";
343
- }, ae = () => {
344
- te.value++;
345
- }, J = P(null), j = b(() => ({
346
- ctaPath: c.config.createRoute,
347
- ctaText: w.value ? c.isServerless ? r("actions.serverless_create") : r("actions.create") : void 0,
348
- message: `${r("gateway_services.list.empty_state.description")}${c.config.additionMessageForEmptyState ? ` ${c.config.additionMessageForEmptyState}` : ""}`,
349
- title: w.value ? c.isServerless ? r("gateway_services.list.empty_state.serverless_title") : r("gateway_services.list.empty_state.title") : r("gateway_services.title")
350
- })), Q = P(!1), E = P(null), X = b(() => {
351
- const u = {
345
+ fetcher: ce,
346
+ fetcherState: t,
347
+ fetcherCacheKey: b
348
+ } = it({ ...n.config, cacheIdentifier: n.cacheIdentifier }, L.value), Se = () => {
349
+ N.value = "";
350
+ }, de = () => {
351
+ b.value++;
352
+ }, j = R(null), Ee = h(() => ({
353
+ ctaPath: n.config.createRoute,
354
+ ctaText: H.value ? n.isServerless ? r("actions.serverless_create") : r("actions.create") : void 0,
355
+ message: `${r("gateway_services.list.empty_state.description")}${n.config.additionMessageForEmptyState ? ` ${n.config.additionMessageForEmptyState}` : ""}`,
356
+ title: H.value ? n.isServerless ? r("gateway_services.list.empty_state.serverless_title") : r("gateway_services.list.empty_state.title") : r("gateway_services.title")
357
+ })), q = R(!1), U = R(null), Y = h(() => {
358
+ const f = {
352
359
  action: "disable",
353
360
  id: "",
354
361
  name: ""
355
362
  };
356
- if (E.value) {
357
- const { enabled: s, id: y, name: T } = E.value;
358
- u.action = s ? "disable" : "enable", u.id = y, u.name = T || y;
363
+ if (U.value) {
364
+ const { enabled: v, id: g, name: V } = U.value;
365
+ f.action = v ? "disable" : "enable", f.id = g, f.name = V || g;
359
366
  }
360
- return u;
361
- }), ke = (u) => {
362
- Q.value = !0, E.value = u;
363
- }, ne = () => {
364
- Q.value = !1, E.value = null;
365
- }, Ce = async () => {
366
- var T, Y;
367
- if (!await ((T = c.canEdit) == null ? void 0 : T.call(c, E.value)) || !E.value)
367
+ return f;
368
+ }), ue = (f) => {
369
+ q.value = !0, U.value = f;
370
+ }, fe = () => {
371
+ q.value = !1, U.value = null;
372
+ }, pe = async () => {
373
+ var V, W;
374
+ if (!await ((V = n.canEdit) == null ? void 0 : V.call(n, U.value)) || !U.value)
368
375
  return;
369
- const s = `${ee.value.href}/${E.value.id}`, y = !E.value.enabled;
376
+ const v = `${F.value.href}/${U.value.id}`, g = !U.value.enabled;
370
377
  try {
371
- const { data: x } = ((Y = c.config) == null ? void 0 : Y.app) === g.Konnect ? await O.put(s, { ...E.value, enabled: y }) : await O.patch(s, { ...E.value, enabled: y });
372
- p("toggle:success", x), E.value.enabled = y;
373
- } catch (x) {
374
- p("error", x);
378
+ const { data: e } = ((W = n.config) == null ? void 0 : W.app) === "konnect" ? await O.put(v, { ...U.value, enabled: g }) : await O.patch(v, { ...U.value, enabled: g });
379
+ p("toggle:success", e), U.value.enabled = g;
380
+ } catch (e) {
381
+ p("error", e);
375
382
  }
376
- }, Ve = (u) => {
377
- c.config.getControlPlaneRoute && W.push(c.config.getControlPlaneRoute(u));
378
- }, le = (u, s) => {
379
- const y = u.id;
380
- if (!s(y)) {
383
+ }, me = (f) => {
384
+ n.config.getControlPlaneRoute && B.push(n.config.getControlPlaneRoute(f));
385
+ }, Ie = (f, v) => {
386
+ const g = f.id;
387
+ if (!v(g)) {
381
388
  p("copy:error", {
382
- entity: u,
389
+ entity: f,
383
390
  field: "id",
384
391
  message: r("errors.copy")
385
392
  });
386
393
  return;
387
394
  }
388
395
  p("copy:success", {
389
- entity: u,
396
+ entity: f,
390
397
  field: "id",
391
- message: r("copy.success", { val: y })
398
+ message: r("copy.success", { val: g })
392
399
  });
393
- }, ce = (u, s) => {
394
- const y = JSON.stringify(u);
395
- if (!s(y)) {
400
+ }, ve = (f, v) => {
401
+ const g = JSON.stringify(f);
402
+ if (!v(g)) {
396
403
  p("copy:error", {
397
- entity: u,
404
+ entity: f,
398
405
  message: r("errors.copy")
399
406
  });
400
407
  return;
401
408
  }
402
409
  p("copy:success", {
403
- entity: u,
410
+ entity: f,
404
411
  message: r("copy.success_brief")
405
412
  });
406
- }, de = async (u) => {
407
- var y;
408
- await ((y = c.canRetrieve) == null ? void 0 : y.call(c, u)) && W.push(c.config.getViewRoute(u.id));
409
- }, Se = (u) => ({
413
+ }, ee = async (f) => {
414
+ var g;
415
+ await ((g = n.canRetrieve) == null ? void 0 : g.call(n, f)) && B.push(n.config.getViewRoute(f.id));
416
+ }, te = (f) => ({
410
417
  label: r("actions.view"),
411
- to: c.config.getViewRoute(u)
412
- }), oe = (u) => ({
418
+ to: n.config.getViewRoute(f)
419
+ }), ge = (f) => ({
413
420
  label: r("actions.edit"),
414
- to: c.config.getEditRoute(u)
415
- }), B = P(void 0), q = P(!1), H = P(!1), Z = P(""), t = ze(c.config, _.value), i = (u) => {
416
- B.value = u, q.value = !0, Z.value = "";
417
- }, v = () => {
418
- q.value = !1, B.value = void 0;
419
- }, R = async () => {
420
- var u, s, y;
421
- if ((u = B.value) != null && u.id) {
422
- H.value = !0;
421
+ to: n.config.getEditRoute(f)
422
+ }), M = R(void 0), oe = R(!1), Z = R(!1), ie = R(""), Fe = lt(n.config, L.value), Pe = (f) => {
423
+ M.value = f, oe.value = !0, ie.value = "";
424
+ }, ye = () => {
425
+ oe.value = !1, M.value = void 0;
426
+ }, le = async () => {
427
+ var f, v, g;
428
+ if ((f = M.value) != null && f.id) {
429
+ Z.value = !0;
423
430
  try {
424
- await O.delete(t(B.value.id)), p("delete:success", B.value), v(), te.value++;
425
- } catch (T) {
426
- Z.value = ((y = (s = T.response) == null ? void 0 : s.data) == null ? void 0 : y.message) || T.message || r("errors.delete"), p("error", T);
431
+ await O.delete(Fe(M.value.id)), p("delete:success", M.value), ye(), b.value++;
432
+ } catch (V) {
433
+ ie.value = ((g = (v = V.response) == null ? void 0 : v.data) == null ? void 0 : g.message) || V.message || r("errors.delete"), p("error", V);
427
434
  } finally {
428
- H.value = !1;
435
+ Z.value = !1;
429
436
  }
430
437
  }
431
- }, S = () => {
432
- W.push(c.config.createRoute);
438
+ }, _e = () => {
439
+ B.push(n.config.createRoute);
433
440
  };
434
- Te(k, (u) => {
435
- var s, y, T;
436
- if (u.status === Je.Error) {
437
- J.value = {
441
+ Ue(t, (f) => {
442
+ var v, g, V;
443
+ if (f.status === rt.Error) {
444
+ j.value = {
438
445
  title: r("errors.general")
439
- }, (T = (y = (s = u.error) == null ? void 0 : s.response) == null ? void 0 : y.data) != null && T.message && (J.value.message = u.error.response.data.message), p("error", u.error);
446
+ }, (V = (g = (v = f.error) == null ? void 0 : v.response) == null ? void 0 : g.data) != null && V.message && (j.value.message = f.error.response.data.message), p("error", f.error);
440
447
  return;
441
448
  }
442
- J.value = null;
449
+ j.value = null;
443
450
  });
444
- const w = P(!1);
445
- return Be(async () => {
446
- w.value = await c.canCreate();
447
- }), (u, s) => {
448
- const y = F("KButton"), T = F("KBadge"), Y = F("KInputSwitch"), x = F("KDropdownItem"), ue = F("KClipboardProvider");
449
- return I(), K("div", wt, [
450
- d(l(Qe), {
451
- "cache-identifier": n.cacheIdentifier,
452
- "default-table-preferences": be,
453
- "disable-sorting": _e.value,
454
- "empty-state-options": j.value,
451
+ const H = R(!1);
452
+ return je(async () => {
453
+ H.value = await n.canCreate();
454
+ }), (f, v) => {
455
+ const g = $("KButton"), V = $("KBadge"), W = $("KInputSwitch"), e = $("KDropdownItem"), i = $("KClipboardProvider");
456
+ return w(), T("div", At, [
457
+ d(o(st), {
458
+ "cache-identifier": a.cacheIdentifier,
459
+ "default-table-preferences": G,
460
+ "disable-sorting": Q.value,
461
+ "empty-state-options": Ee.value,
455
462
  "enable-entity-actions": "",
456
- "error-message": J.value,
457
- fetcher: l(e),
458
- "fetcher-cache-key": l(te),
463
+ "error-message": j.value,
464
+ fetcher: o(ce),
465
+ "fetcher-cache-key": o(b),
459
466
  "pagination-type": "offset",
460
467
  "preferences-storage-key": "kong-ui-entities-gateway-services-list",
461
- query: G.value,
462
- "table-headers": l(z),
463
- onClearSearchInput: we,
464
- "onClick:row": s[5] || (s[5] = (m) => de(m)),
465
- onSort: ae,
466
- onState: l(U)
467
- }, Le({
468
- "toolbar-filter": f(() => [
469
- d(l(Xe), {
470
- modelValue: G.value,
471
- "onUpdate:modelValue": s[0] || (s[0] = (m) => G.value = m),
472
- config: he.value
468
+ query: N.value,
469
+ "table-headers": o(Ve),
470
+ onClearSearchInput: Se,
471
+ "onClick:row": v[5] || (v[5] = (c) => ee(c)),
472
+ onSort: de,
473
+ onState: o(A)
474
+ }, ze({
475
+ "toolbar-filter": u(() => [
476
+ d(o(at), {
477
+ modelValue: N.value,
478
+ "onUpdate:modelValue": v[0] || (v[0] = (c) => N.value = c),
479
+ config: X.value
473
480
  }, null, 8, ["modelValue", "config"])
474
481
  ]),
475
- "toolbar-button": f(() => [
476
- (I(), fe(Pe, {
477
- disabled: !n.useActionOutside,
482
+ "toolbar-button": u(() => [
483
+ (w(), se(xe, {
484
+ disabled: !a.useActionOutside,
478
485
  to: "#kong-ui-app-page-header-action-button"
479
486
  }, [
480
- C("div", kt, [
481
- V.value ? (I(), fe(y, {
487
+ E("div", Ut, [
488
+ k.value ? (w(), se(g, {
482
489
  key: 0,
483
490
  appearance: "secondary",
484
491
  class: "open-learning-hub",
485
492
  "data-testid": "gateway-services-learn-more-button",
486
493
  icon: "",
487
- onClick: s[1] || (s[1] = (m) => u.$emit("click:learn-more"))
494
+ onClick: v[1] || (v[1] = (c) => f.$emit("click:learn-more"))
488
495
  }, {
489
- default: f(() => [
490
- d(l(Ke), { decorative: "" })
496
+ default: u(() => [
497
+ d(o(Be), { decorative: "" })
491
498
  ]),
492
499
  _: 1
493
- })) : L("", !0),
494
- d(l(se), {
495
- "auth-function": () => n.canCreate()
500
+ })) : x("", !0),
501
+ d(o(re), {
502
+ "auth-function": () => a.canCreate()
496
503
  }, {
497
- default: f(() => [
498
- d(y, {
504
+ default: u(() => [
505
+ d(g, {
499
506
  appearance: "primary",
500
507
  "data-testid": "toolbar-add-gateway-service",
501
- size: n.useActionOutside ? "medium" : "large",
502
- to: n.config.createRoute
508
+ size: a.useActionOutside ? "medium" : "large",
509
+ to: a.config.createRoute
503
510
  }, {
504
- default: f(() => [
505
- d(l(qe)),
506
- M(" " + h(l(r)("gateway_services.list.toolbar_actions.new_gateway_service")), 1)
511
+ default: u(() => [
512
+ d(o(Xe)),
513
+ K(" " + I(o(r)("gateway_services.list.toolbar_actions.new_gateway_service")), 1)
507
514
  ]),
508
515
  _: 1
509
516
  }, 8, ["size", "to"])
@@ -513,120 +520,120 @@ const ye = {
513
520
  ])
514
521
  ], 8, ["disabled"]))
515
522
  ]),
516
- name: f(({ rowValue: m }) => [
517
- C("b", null, h(m ?? "-"), 1)
523
+ name: u(({ rowValue: c }) => [
524
+ E("b", null, I(c ?? "-"), 1)
518
525
  ]),
519
- control_plane: f(({ row: m }) => {
520
- var A;
526
+ control_plane: u(({ row: c }) => {
527
+ var _;
521
528
  return [
522
- (A = m.x_meta) != null && A.cluster_id ? (I(), fe(T, {
529
+ (_ = c.x_meta) != null && _.cluster_id ? (w(), se(V, {
523
530
  key: 0,
524
- tooltip: m.x_meta.cluster_id,
531
+ tooltip: c.x_meta.cluster_id,
525
532
  "truncation-tooltip": "",
526
- onClick: Ie((ie) => Ve(m.x_meta.cluster_id), ["stop"])
533
+ onClick: Te((y) => me(c.x_meta.cluster_id), ["stop"])
527
534
  }, {
528
- default: f(() => [
529
- M(h(m.x_meta.cluster_id), 1)
535
+ default: u(() => [
536
+ K(I(c.x_meta.cluster_id), 1)
530
537
  ]),
531
538
  _: 2
532
- }, 1032, ["tooltip", "onClick"])) : (I(), K("b", Vt, "-"))
539
+ }, 1032, ["tooltip", "onClick"])) : (w(), T("b", xt, "-"))
533
540
  ];
534
541
  }),
535
- enabled: f(({ row: m }) => [
536
- d(l(se), {
537
- "auth-function": () => n.canEdit(m),
542
+ enabled: u(({ row: c }) => [
543
+ d(o(re), {
544
+ "auth-function": () => a.canEdit(c),
538
545
  "force-show": ""
539
546
  }, {
540
- default: f(({ isAllowed: A }) => [
541
- C("div", {
542
- onClick: s[4] || (s[4] = Ie(() => {
547
+ default: u(({ isAllowed: _ }) => [
548
+ E("div", {
549
+ onClick: v[4] || (v[4] = Te(() => {
543
550
  }, ["stop"]))
544
551
  }, [
545
- d(Y, {
546
- modelValue: m.enabled,
547
- "onUpdate:modelValue": (ie) => m.enabled = ie,
548
- "data-testid": `row-${m.id}-toggle-input`,
549
- disabled: !A,
550
- onClick: Ie((ie) => ke(m), ["prevent"])
552
+ d(W, {
553
+ modelValue: c.enabled,
554
+ "onUpdate:modelValue": (y) => c.enabled = y,
555
+ "data-testid": `row-${c.id}-toggle-input`,
556
+ disabled: !_,
557
+ onClick: Te((y) => ue(c), ["prevent"])
551
558
  }, null, 8, ["modelValue", "onUpdate:modelValue", "data-testid", "disabled", "onClick"])
552
559
  ])
553
560
  ]),
554
561
  _: 2
555
562
  }, 1032, ["auth-function"])
556
563
  ]),
557
- tags: f(({ rowValue: m }) => [
558
- d(l(Ze), { tags: m }, null, 8, ["tags"])
564
+ tags: u(({ rowValue: c }) => [
565
+ d(o(nt), { tags: c }, null, 8, ["tags"])
559
566
  ]),
560
- created_at: f(({ rowValue: m }) => [
561
- M(h(l($)(m)), 1)
567
+ created_at: u(({ rowValue: c }) => [
568
+ K(I(o(C)(c)), 1)
562
569
  ]),
563
- updated_at: f(({ row: m, rowValue: A }) => [
564
- M(h(l($)(A ?? m.created_at)), 1)
570
+ updated_at: u(({ row: c, rowValue: _ }) => [
571
+ K(I(o(C)(_ ?? c.created_at)), 1)
565
572
  ]),
566
- actions: f(({ row: m }) => [
567
- d(ue, null, {
568
- default: f(({ copyToClipboard: A }) => [
569
- d(x, {
573
+ actions: u(({ row: c }) => [
574
+ d(i, null, {
575
+ default: u(({ copyToClipboard: _ }) => [
576
+ d(e, {
570
577
  "data-testid": "action-entity-copy-id",
571
- onClick: (ie) => le(m, A)
578
+ onClick: (y) => Ie(c, _)
572
579
  }, {
573
- default: f(() => [
574
- M(h(l(r)("actions.copy_id")), 1)
580
+ default: u(() => [
581
+ K(I(o(r)("actions.copy_id")), 1)
575
582
  ]),
576
583
  _: 2
577
584
  }, 1032, ["onClick"])
578
585
  ]),
579
586
  _: 2
580
587
  }, 1024),
581
- d(ue, null, {
582
- default: f(({ copyToClipboard: A }) => [
583
- d(x, {
588
+ d(i, null, {
589
+ default: u(({ copyToClipboard: _ }) => [
590
+ d(e, {
584
591
  "data-testid": "action-entity-copy-json",
585
- onClick: (ie) => ce(m, A)
592
+ onClick: (y) => ve(c, _)
586
593
  }, {
587
- default: f(() => [
588
- M(h(l(r)("actions.copy_json")), 1)
594
+ default: u(() => [
595
+ K(I(o(r)("actions.copy_json")), 1)
589
596
  ]),
590
597
  _: 2
591
598
  }, 1032, ["onClick"])
592
599
  ]),
593
600
  _: 2
594
601
  }, 1024),
595
- d(l(se), {
596
- "auth-function": () => n.canRetrieve(m)
602
+ d(o(re), {
603
+ "auth-function": () => a.canRetrieve(c)
597
604
  }, {
598
- default: f(() => [
599
- d(x, {
605
+ default: u(() => [
606
+ d(e, {
600
607
  "data-testid": "action-entity-view",
601
608
  "has-divider": "",
602
- item: Se(m.id)
609
+ item: te(c.id)
603
610
  }, null, 8, ["item"])
604
611
  ]),
605
612
  _: 2
606
613
  }, 1032, ["auth-function"]),
607
- d(l(se), {
608
- "auth-function": () => n.canEdit(m)
614
+ d(o(re), {
615
+ "auth-function": () => a.canEdit(c)
609
616
  }, {
610
- default: f(() => [
611
- d(x, {
617
+ default: u(() => [
618
+ d(e, {
612
619
  "data-testid": "action-entity-edit",
613
- item: oe(m.id)
620
+ item: ge(c.id)
614
621
  }, null, 8, ["item"])
615
622
  ]),
616
623
  _: 2
617
624
  }, 1032, ["auth-function"]),
618
- d(l(se), {
619
- "auth-function": () => n.canDelete(m)
625
+ d(o(re), {
626
+ "auth-function": () => a.canDelete(c)
620
627
  }, {
621
- default: f(() => [
622
- d(x, {
628
+ default: u(() => [
629
+ d(e, {
623
630
  danger: "",
624
631
  "data-testid": "action-entity-delete",
625
632
  "has-divider": "",
626
- onClick: (A) => i(m)
633
+ onClick: (_) => Pe(c)
627
634
  }, {
628
- default: f(() => [
629
- M(h(l(r)("actions.delete.menu_label")), 1)
635
+ default: u(() => [
636
+ K(I(o(r)("actions.delete.menu_label")), 1)
630
637
  ]),
631
638
  _: 2
632
639
  }, 1032, ["onClick"])
@@ -636,22 +643,22 @@ const ye = {
636
643
  ]),
637
644
  _: 2
638
645
  }, [
639
- !l(a) && ge.value ? {
646
+ !o(s) && D.value ? {
640
647
  name: "outside-actions",
641
- fn: f(() => [
642
- (I(), fe(Pe, {
643
- disabled: !n.useActionOutside,
648
+ fn: u(() => [
649
+ (w(), se(xe, {
650
+ disabled: !a.useActionOutside,
644
651
  to: "#kong-ui-app-page-header-action-button"
645
652
  }, [
646
- d(y, {
653
+ d(g, {
647
654
  appearance: "secondary",
648
655
  class: "open-learning-hub",
649
656
  "data-testid": "gateway-services-more-button",
650
657
  icon: "",
651
- onClick: s[2] || (s[2] = (m) => u.$emit("click:learn-more"))
658
+ onClick: v[2] || (v[2] = (c) => f.$emit("click:learn-more"))
652
659
  }, {
653
- default: f(() => [
654
- d(l(Ke), { decorative: "" })
660
+ default: u(() => [
661
+ d(o(Be), { decorative: "" })
655
662
  ]),
656
663
  _: 1
657
664
  })
@@ -659,25 +666,25 @@ const ye = {
659
666
  ]),
660
667
  key: "0"
661
668
  } : void 0,
662
- n.enableV2EmptyStates && n.config.app === l(g).Konnect ? {
669
+ a.enableV2EmptyStates && a.config.app === "konnect" ? {
663
670
  name: "empty-state",
664
- fn: f(() => [
665
- d(l(Ye), {
666
- "action-button-text": l(r)("gateway_services.empty_state_v2.create"),
671
+ fn: u(() => [
672
+ d(o(ct), {
673
+ "action-button-text": o(r)("gateway_services.empty_state_v2.create"),
667
674
  appearance: "secondary",
668
- "can-create": () => n.canCreate(),
675
+ "can-create": () => a.canCreate(),
669
676
  "data-testid": "gateway-services-entity-empty-state",
670
- description: l(r)("gateway_services.empty_state_v2.description"),
671
- "learn-more": n.config.app === l(g).Konnect,
672
- title: l(r)("gateway_services.empty_state_v2.title"),
673
- "onClick:create": S,
674
- "onClick:learnMore": s[3] || (s[3] = (m) => u.$emit("click:learn-more"))
677
+ description: o(r)("gateway_services.empty_state_v2.description"),
678
+ "learn-more": a.config.app === "konnect",
679
+ title: o(r)("gateway_services.empty_state_v2.title"),
680
+ "onClick:create": _e,
681
+ "onClick:learnMore": v[3] || (v[3] = (c) => f.$emit("click:learn-more"))
675
682
  }, {
676
- image: f(() => [
677
- C("div", Ct, [
678
- d(l(Oe), {
679
- color: l(bt),
680
- size: l(ht)
683
+ image: u(() => [
684
+ E("div", Rt, [
685
+ d(o(Ye), {
686
+ color: o(Pt),
687
+ size: o(Tt)
681
688
  }, null, 8, ["color", "size"])
682
689
  ])
683
690
  ]),
@@ -687,64 +694,105 @@ const ye = {
687
694
  key: "1"
688
695
  } : void 0
689
696
  ]), 1032, ["cache-identifier", "disable-sorting", "empty-state-options", "error-message", "fetcher", "fetcher-cache-key", "query", "table-headers", "onState"]),
690
- d(l(et), {
691
- action: X.value.action,
692
- "entity-id": X.value.id,
693
- "entity-name": X.value.name,
694
- "entity-type": l(r)("glossary.gateway_services"),
695
- "on-confirm": Ce,
696
- visible: Q.value,
697
- onCancel: ne,
698
- onProceed: ne
699
- }, null, 8, ["action", "entity-id", "entity-name", "entity-type", "visible"]),
700
- d(l(tt), {
701
- "action-pending": H.value,
702
- description: l(r)("actions.delete.description"),
703
- "entity-name": B.value && (B.value.name || B.value.id),
704
- "entity-type": l(lt).GatewayService,
705
- error: Z.value,
706
- title: l(r)("actions.delete.title"),
697
+ d(o(dt), {
698
+ action: Y.value.action,
699
+ "entity-id": Y.value.id,
700
+ "entity-name": Y.value.name,
701
+ "entity-type": o(r)("glossary.gateway_services"),
702
+ "on-confirm": pe,
707
703
  visible: q.value,
708
- onCancel: v,
709
- onProceed: R
704
+ onCancel: fe,
705
+ onProceed: fe
706
+ }, null, 8, ["action", "entity-id", "entity-name", "entity-type", "visible"]),
707
+ d(o(ut), {
708
+ "action-pending": Z.value,
709
+ description: o(r)("actions.delete.description"),
710
+ "entity-name": M.value && (M.value.name || M.value.id),
711
+ "entity-type": o(ft).GatewayService,
712
+ error: ie.value,
713
+ title: o(r)("actions.delete.title"),
714
+ visible: oe.value,
715
+ onCancel: ye,
716
+ onProceed: le
710
717
  }, null, 8, ["action-pending", "description", "entity-name", "entity-type", "error", "title", "visible"])
711
718
  ]);
712
719
  };
713
720
  }
714
- }), Fe = (n, D) => {
715
- const p = n.__vccOpts || n;
716
- for (const [c, r] of D)
717
- p[c] = r;
721
+ }), Ge = (a, P) => {
722
+ const p = a.__vccOpts || a;
723
+ for (const [n, r] of P)
724
+ p[n] = r;
725
+ return p;
726
+ }, co = /* @__PURE__ */ Ge($t, [["__scopeId", "data-v-fa0c855e"]]);
727
+ typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
728
+ const Ke = () => {
729
+ };
730
+ function Mt(a, P) {
731
+ function p(...n) {
732
+ return new Promise((r, C) => {
733
+ Promise.resolve(a(() => P.apply(this, n), { fn: P, thisArg: this, args: n })).then(r).catch(C);
734
+ });
735
+ }
718
736
  return p;
719
- }, Qt = /* @__PURE__ */ Fe(St, [["__scopeId", "data-v-3493f686"]]), It = { class: "kong-ui-entities-gateway-service-form" }, Tt = { key: 0 }, Et = { class: "gateway-service-form-traffic-label" }, Pt = { class: "gateway-service-form-margin-bottom" }, Ut = {
737
+ }
738
+ function Bt(a, P = {}) {
739
+ let p, n, r = Ke;
740
+ const C = (s) => {
741
+ clearTimeout(s), r(), r = Ke;
742
+ };
743
+ let B;
744
+ return (s) => {
745
+ const A = $e(a), k = $e(P.maxWait);
746
+ return p && C(p), A <= 0 || k !== void 0 && k <= 0 ? (n && (C(n), n = null), Promise.resolve(s())) : new Promise((D, Q) => {
747
+ r = P.rejectOnCancel ? Q : D, B = s, k && !n && (n = setTimeout(() => {
748
+ p && C(p), n = null, D(B());
749
+ }, k)), p = setTimeout(() => {
750
+ n && C(n), n = null, D(s());
751
+ }, A);
752
+ });
753
+ };
754
+ }
755
+ function Oe(a, P = 200, p = {}) {
756
+ return Mt(
757
+ Bt(P, p),
758
+ a
759
+ );
760
+ }
761
+ const Dt = { class: "kong-ui-entities-gateway-service-form" }, Lt = {
762
+ key: 0,
763
+ class: "gateway-service-form-general-info"
764
+ }, Kt = { class: "gateway-service-form-group-selection-wrapper" }, Ot = {
720
765
  key: 0,
721
766
  class: "gateway-service-form-group-fields"
722
- }, Kt = {
723
- key: 1,
767
+ }, Nt = {
768
+ key: 0,
724
769
  class: "gateway-service-form-group-fields"
725
- }, Rt = { key: 0 }, Mt = { class: "gateway-service-form-margin-top" }, $t = { class: "gateway-service-form-margin-bottom" }, xt = { class: "gateway-service-form-margin-bottom" }, At = { class: "gateway-service-form-margin-bottom" }, Ft = { class: "gateway-service-form-margin-bottom" }, Bt = {
770
+ }, qt = { key: 0 }, Wt = {
771
+ key: 0,
772
+ class: "gateway-service-form-advanced-fields"
773
+ }, Gt = { class: "gateway-service-form-margin-bottom" }, jt = { class: "gateway-service-form-margin-bottom" }, zt = { class: "gateway-service-form-margin-bottom" }, Zt = { class: "gateway-service-form-margin-bottom" }, Ht = {
726
774
  key: 0,
727
775
  class: "gateway-service-form-margin-bottom"
728
- }, Lt = {
776
+ }, Jt = {
729
777
  key: 1,
730
778
  class: "gateway-service-form-margin-bottom"
731
- }, Dt = {
779
+ }, Qt = {
732
780
  key: 2,
733
781
  class: "gateway-service-form-margin-bottom"
734
- }, Gt = {
782
+ }, Xt = {
735
783
  key: 0,
736
784
  class: "checkbox-aligned-radio"
737
- }, qt = {
785
+ }, Yt = {
738
786
  key: 1,
739
787
  class: "checkbox-aligned-radio"
740
- }, Ot = /* @__PURE__ */ Ee({
788
+ }, eo = { class: "gateway-service-form-tags" }, to = { class: "form-error-list" }, oo = /* @__PURE__ */ Re({
741
789
  __name: "GatewayServiceForm",
742
790
  props: {
743
791
  /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
744
792
  config: {
745
793
  type: Object,
746
794
  required: !0,
747
- validator: (n) => !(!n || ![g.Konnect, g.KongManager].includes(n == null ? void 0 : n.app) || n.app === g.Konnect && !n.controlPlaneId || n.app === g.KongManager && typeof n.workspace != "string" || !n.cancelRoute)
795
+ validator: (a) => !(!a || !["konnect", "kongManager"].includes(a == null ? void 0 : a.app) || a.app === "konnect" && !a.controlPlaneId || a.app === "kongManager" && typeof a.workspace != "string" || !a.cancelRoute)
748
796
  },
749
797
  /** If a valid Gateway Service ID is provided, it will put the form in Edit mode instead of Create */
750
798
  gatewayServiceId: {
@@ -757,12 +805,23 @@ const ye = {
757
805
  type: Boolean,
758
806
  required: !1,
759
807
  default: !1
808
+ },
809
+ /** Whether show or hide Try sample API button */
810
+ hideTrySampleAPIButton: {
811
+ type: Boolean,
812
+ required: !1,
813
+ default: !1
814
+ },
815
+ sampleApiList: {
816
+ type: Array,
817
+ required: !1,
818
+ default: () => []
760
819
  }
761
820
  },
762
- emits: ["update", "error", "url-valid:success", "url-valid:error", "loading", "model-updated"],
763
- setup(n, { expose: D, emit: p }) {
764
- var Z;
765
- const c = p, r = n, $ = P(!0), W = $e(), { i18nT: O, i18n: { t: a } } = ye.useI18n(), { getMessageFromError: U } = ot(), { axiosInstance: V } = xe((Z = r.config) == null ? void 0 : Z.axiosRequestConfig), ge = it(), _e = b(() => re.form[r.config.app].edit), N = b(() => r.gatewayServiceId ? Re.Edit : Re.Create), be = P(!1), z = b(() => !!r.gatewayServiceId), _ = P(z.value ? "protocol" : "url"), ee = ye.usePortFromProtocol(), G = P(""), he = b(() => !!G.value), e = Ue({
821
+ emits: ["update", "error", "url-valid:success", "url-valid:error", "loading", "model-updated", "try-sample-api"],
822
+ setup(a, { expose: P, emit: p }) {
823
+ var W;
824
+ const n = p, r = a, C = R(!0), B = Ne(), { i18nT: O, i18n: { t: s } } = Ce.useI18n(), { getMessageFromError: A, getErrorFieldsFromError: k } = pt(), { axiosInstance: D } = qe((W = r.config) == null ? void 0 : W.axiosRequestConfig), Q = mt(), ne = h(() => ae.form[r.config.app].edit), G = h(() => r.gatewayServiceId ? De.Edit : De.Create), Ve = R(!1), L = h(() => !!r.gatewayServiceId), F = R(L.value ? "protocol" : "url"), N = Ce.usePortFromProtocol(), X = R(""), ce = h(() => !!X.value), t = Me({
766
825
  fields: {
767
826
  name: "",
768
827
  protocol: "http",
@@ -781,8 +840,23 @@ const ye = {
781
840
  tags: ""
782
841
  },
783
842
  isReadonly: !1,
784
- errorMessage: ""
785
- }), k = Ue({
843
+ errorMessages: [],
844
+ formFieldErrors: {
845
+ host: "",
846
+ port: "",
847
+ path: "",
848
+ url: "",
849
+ tags: "",
850
+ retries: "",
851
+ connect_timeout: "",
852
+ write_timeout: "",
853
+ read_timeout: "",
854
+ client_certificate: "",
855
+ ca_certificates: "",
856
+ tls_verify_enabled: "",
857
+ tls_verify_value: ""
858
+ }
859
+ }), b = Me({
786
860
  name: "",
787
861
  protocol: "http",
788
862
  host: "",
@@ -798,564 +872,674 @@ const ye = {
798
872
  tls_verify_enabled: !1,
799
873
  tls_verify_value: !1,
800
874
  tags: ""
801
- }), te = r.config.app === g.Konnect || st({
875
+ }), Se = r.config.app === "konnect" || vt({
802
876
  gatewayInfo: r.config.gatewayInfo,
803
877
  // 'ws' and 'wss' are not valid values for the protocol field in Gateway Community Edition or before Gateway Enterprise Edition 3.0
804
878
  supportedRange: {
805
879
  enterprise: ["3.0"]
806
880
  }
807
- }), we = [
881
+ }), de = [
808
882
  {
809
- label: a("gateway_services.form.fields.protocol.options.http"),
883
+ label: s("gateway_services.form.fields.protocol.options.http"),
810
884
  value: "http",
811
885
  group: "http"
812
886
  },
813
887
  {
814
- label: a("gateway_services.form.fields.protocol.options.https"),
888
+ label: s("gateway_services.form.fields.protocol.options.https"),
815
889
  value: "https",
816
890
  group: "http"
817
891
  },
818
892
  {
819
- label: a("gateway_services.form.fields.protocol.options.tcp"),
893
+ label: s("gateway_services.form.fields.protocol.options.tcp"),
820
894
  value: "tcp",
821
895
  group: "tcp"
822
896
  },
823
897
  {
824
- label: a("gateway_services.form.fields.protocol.options.tls"),
898
+ label: s("gateway_services.form.fields.protocol.options.tls"),
825
899
  value: "tls",
826
900
  group: "tcp"
827
901
  },
828
902
  {
829
- label: a("gateway_services.form.fields.protocol.options.tls_passthrough"),
903
+ label: s("gateway_services.form.fields.protocol.options.tls_passthrough"),
830
904
  value: "tls_passthrough",
831
905
  group: "tcp"
832
906
  },
833
907
  {
834
- label: a("gateway_services.form.fields.protocol.options.grpc"),
908
+ label: s("gateway_services.form.fields.protocol.options.grpc"),
835
909
  value: "grpc",
836
910
  group: "grpc"
837
911
  },
838
912
  {
839
- label: a("gateway_services.form.fields.protocol.options.grpcs"),
913
+ label: s("gateway_services.form.fields.protocol.options.grpcs"),
840
914
  value: "grpcs",
841
915
  group: "grpc"
842
916
  },
843
- ...te ? [
917
+ ...Se ? [
844
918
  {
845
- label: a("gateway_services.form.fields.protocol.options.ws"),
919
+ label: s("gateway_services.form.fields.protocol.options.ws"),
846
920
  value: "ws",
847
921
  group: "websocket"
848
922
  },
849
923
  {
850
- label: a("gateway_services.form.fields.protocol.options.wss"),
924
+ label: s("gateway_services.form.fields.protocol.options.wss"),
851
925
  value: "wss",
852
926
  group: "websocket"
853
927
  }
854
928
  ] : [],
855
929
  {
856
- label: a("gateway_services.form.fields.protocol.options.udp"),
930
+ label: s("gateway_services.form.fields.protocol.options.udp"),
857
931
  value: "udp",
858
932
  group: "udp"
859
933
  }
860
- ], ae = { url: "url", protocol: "protocol" }, J = (t, i) => {
934
+ ], j = { url: "url", protocol: "protocol" }, Ee = (e, i) => {
861
935
  i.value;
862
- }, j = (t) => t ? parseFloat(t) : 0, Q = () => {
863
- $.value = !0, e.errorMessage = "", e.fields.host = k.host, e.fields.path = k.path, e.fields.port = k.port, e.fields.protocol = k.protocol, e.fields.url = k.url, e.fields.retries = k.retries, e.fields.connect_timeout = k.connect_timeout, e.fields.write_timeout = k.write_timeout, e.fields.read_timeout = k.read_timeout, e.fields.client_certificate = k.client_certificate, e.fields.ca_certificates = k.ca_certificates, e.fields.tls_verify_enabled = k.tls_verify_enabled, e.fields.tls_verify_value = k.tls_verify_value;
864
- }, E = () => {
865
- if (e.fields.url && _.value === "url")
936
+ }, q = (e) => e ? parseFloat(e) : 0, U = () => {
937
+ C.value = !0, te(), t.errorMessages = [], t.fields.host = b.host, t.fields.path = b.path, t.fields.port = b.port, t.fields.protocol = b.protocol, t.fields.url = b.url, t.fields.retries = b.retries, t.fields.connect_timeout = b.connect_timeout, t.fields.write_timeout = b.write_timeout, t.fields.read_timeout = b.read_timeout, t.fields.client_certificate = b.client_certificate, t.fields.ca_certificates = b.ca_certificates, t.fields.tls_verify_enabled = b.tls_verify_enabled, t.fields.tls_verify_value = b.tls_verify_value;
938
+ }, Y = () => {
939
+ Ie();
940
+ }, ue = (e) => !e || e.trim() === "" ? "host cannot be empty" : /^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$|^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/.test(e) ? "" : "invalid host", fe = (e) => !e || e.trim() === "" ? "protocol cannot be empty" : (e = e.slice(0, -1), de.find((c) => {
941
+ if (c.value === e) return c;
942
+ }) === void 0 ? 'protocol - value must be one of "http", "https", "grpc", "grpcs", "tcp", "udp", "tls", "tls_passthrough", "ws", "wss"' : ""), pe = (e) => {
943
+ if (e == null || e === "")
944
+ return "";
945
+ const i = typeof e == "string" ? parseInt(e, 10) : e;
946
+ return isNaN(i) ? "Port must be a number" : i < 0 || i > 65535 ? "Port must be between 0 and 65535" : "";
947
+ }, me = (e) => !e || e === "" ? "" : e.startsWith("/") ? /[^A-Za-z0-9\-._~:/?#[\]@!$&'()*+,;=%]/.test(e) ? "Path should not include characters outside of the reserved list of RFC 3986" : "" : "Path must begin with /", Ie = Oe(() => {
948
+ if (te(), t.fields.url.length)
949
+ try {
950
+ const e = new URL(t.fields.url), i = fe(e.protocol);
951
+ if (i) throw new Error(i);
952
+ const c = ue(e.hostname);
953
+ if (c) throw new Error(c);
954
+ const _ = me(e.pathname);
955
+ if (_) throw new Error(_);
956
+ const y = pe(e.port);
957
+ if (y) throw new Error(y);
958
+ } catch (e) {
959
+ n("url-valid:error", e.message || "URL validation failed"), t.formFieldErrors.url = e.message || "URL validation failed";
960
+ }
961
+ }, 300), ve = h(() => (e) => {
962
+ const i = t.formFieldErrors;
963
+ return e === "url" ? i.host.length ? i.host : i.path.length ? i.path : i.url : i[e] ? i[e] : "";
964
+ }), ee = Oe(() => {
965
+ te();
966
+ const e = ue(t.fields.host);
967
+ e && (t.formFieldErrors.host = e);
968
+ const i = me(t.fields.path);
969
+ i && (t.formFieldErrors.path = i);
970
+ const c = pe(t.fields.port);
971
+ c && (t.formFieldErrors.port = c);
972
+ }, 300), te = () => {
973
+ t.formFieldErrors = {
974
+ host: "",
975
+ port: "",
976
+ url: "",
977
+ path: "",
978
+ tags: "",
979
+ retries: "",
980
+ connect_timeout: "",
981
+ write_timeout: "",
982
+ read_timeout: "",
983
+ client_certificate: "",
984
+ ca_certificates: "",
985
+ tls_verify_enabled: "",
986
+ tls_verify_value: ""
987
+ };
988
+ }, ge = h(() => Object.values(t.formFieldErrors).some((e) => e !== null && e !== "") && !ce.value), M = () => {
989
+ if (t.fields.url && F.value === "url")
866
990
  try {
867
- const t = new URL(e.fields.url);
868
- e.errorMessage = "", e.fields.protocol = t.protocol.slice(0, -1), e.fields.host = t.hostname, e.fields.path = t.pathname;
869
- const i = Number(t.port);
870
- be.value = !!i, e.fields.port = i || ee.getPortFromProtocol(e.fields.protocol), e.errorMessage = "", c("url-valid:success");
871
- } catch (t) {
872
- e.errorMessage = a("errors.urlErrorMessage"), c("url-valid:error", U(t));
991
+ const e = new URL(t.fields.url);
992
+ t.fields.protocol = e.protocol.slice(0, -1), t.fields.host = e.hostname, t.fields.path = e.pathname;
993
+ const i = Number(e.port);
994
+ Ve.value = !!i, t.fields.port = i || N.getPortFromProtocol(t.fields.protocol), n("url-valid:success");
995
+ } catch (e) {
996
+ n("url-valid:error", A(e));
873
997
  }
874
998
  else
875
- c("url-valid:success"), e.errorMessage = "";
876
- }, X = b(() => !["tcp", "tls", "tls_passthrough", "grpc", "grpcs", "udp"].includes(e.fields.protocol)), ke = b(() => {
877
- if (_.value === "url")
999
+ n("url-valid:success");
1000
+ }, oe = () => `new-service-${(/* @__PURE__ */ new Date()).toISOString().replace(/\D/g, "").slice(0, 17)}`, Z = h(() => !["tcp", "tls", "tls_passthrough", "grpc", "grpcs", "udp"].includes(t.fields.protocol)), ie = h(() => {
1001
+ if (F.value === "url")
878
1002
  return !0;
879
- const t = ["https", "wss", "tls"].includes(e.fields.protocol);
880
- return _.value === "protocol" && t;
881
- }), ne = b(() => {
882
- if (_.value === "url")
1003
+ const e = ["https", "wss", "tls"].includes(t.fields.protocol);
1004
+ return F.value === "protocol" && e;
1005
+ }), Fe = h(() => {
1006
+ if (F.value === "url")
883
1007
  return !0;
884
- const t = ["https", "tls"].includes(e.fields.protocol);
885
- return _.value === "protocol" && t;
886
- }), Ce = b(() => {
887
- if (_.value === "url")
1008
+ const e = ["https", "tls"].includes(t.fields.protocol);
1009
+ return F.value === "protocol" && e;
1010
+ }), Pe = h(() => {
1011
+ if (F.value === "url")
888
1012
  return !0;
889
- const t = ["https", "wss", "tls"].includes(e.fields.protocol);
890
- return _.value === "protocol" && t;
891
- }), Ve = (t) => {
892
- G.value = ge.utf8Name(t);
893
- }, le = b(() => z.value && JSON.stringify(e.fields) !== JSON.stringify(k) || _.value === "url" && !!e.fields.url || _.value === "protocol" && !!e.fields.host), ce = (t) => {
894
- var i, v, R;
895
- e.fields.name = (t == null ? void 0 : t.name) || "", e.fields.tags = ((i = t == null ? void 0 : t.tags) == null ? void 0 : i.join(", ")) || "", e.fields.protocol = (t == null ? void 0 : t.protocol) || "http", e.fields.path = (t == null ? void 0 : t.path) || "", e.fields.read_timeout = t != null && t.read_timeout || (t == null ? void 0 : t.read_timeout) === 0 ? t == null ? void 0 : t.read_timeout : 6e4, e.fields.retries = t != null && t.retries || (t == null ? void 0 : t.retries) === 0 ? t == null ? void 0 : t.retries : 5, e.fields.host = (t == null ? void 0 : t.host) || "", e.fields.connect_timeout = t != null && t.connect_timeout || (t == null ? void 0 : t.connect_timeout) === 0 ? t == null ? void 0 : t.connect_timeout : 6e4, e.fields.tls_verify_enabled = (t == null ? void 0 : t.tls_verify) !== "" && (t == null ? void 0 : t.tls_verify) !== null && (t == null ? void 0 : t.tls_verify) !== void 0, e.fields.tls_verify_value = t != null && t.tls_verify ? t == null ? void 0 : t.tls_verify : !1, e.fields.ca_certificates = ((v = t == null ? void 0 : t.ca_certificates) == null ? void 0 : v.join(",")) || "", e.fields.client_certificate = ((R = t == null ? void 0 : t.client_certificate) == null ? void 0 : R.id) || "", e.fields.write_timeout = t != null && t.write_timeout || (t == null ? void 0 : t.write_timeout) === 0 ? t == null ? void 0 : t.write_timeout : 6e4, e.fields.port = t != null && t.port || (t == null ? void 0 : t.port) === 0 ? t == null ? void 0 : t.port : 80, Object.assign(k, e.fields);
896
- }, de = () => {
897
- W.push(r.config.cancelRoute);
898
- }, Se = b(() => {
899
- var i, v;
900
- let t = `${r.config.apiBaseUrl}${re.form[r.config.app].validate}`;
901
- return r.config.app === g.Konnect ? t = t.replace(/{controlPlaneId}/gi, ((i = r.config) == null ? void 0 : i.controlPlaneId) || "") : r.config.app === g.KongManager && (t = t.replace(/\/{workspace}/gi, (v = r.config) != null && v.workspace ? `/${r.config.workspace}` : "")), t = t.replace(/{id}/gi, r.gatewayServiceId), t;
902
- }), oe = b(() => {
903
- var i, v;
904
- let t = `${r.config.apiBaseUrl}${re.form[r.config.app][N.value]}`;
905
- return r.config.app === g.Konnect ? t = t.replace(/{controlPlaneId}/gi, ((i = r.config) == null ? void 0 : i.controlPlaneId) || "") : r.config.app === g.KongManager && (t = t.replace(/\/{workspace}/gi, (v = r.config) != null && v.workspace ? `/${r.config.workspace}` : "")), t = t.replace(/{id}/gi, r.gatewayServiceId), t;
906
- }), B = (t) => {
1013
+ const e = ["https", "wss", "tls"].includes(t.fields.protocol);
1014
+ return F.value === "protocol" && e;
1015
+ }), ye = (e) => {
1016
+ X.value = Q.utf8Name(e);
1017
+ }, le = h(() => L.value && JSON.stringify(t.fields) !== JSON.stringify(b) || F.value === "url" && !!t.fields.url && !ge.value || F.value === "protocol" && !!t.fields.host && !ge.value), _e = (e) => {
1018
+ var i, c, _;
1019
+ t.fields.name = (e == null ? void 0 : e.name) || "", t.fields.tags = ((i = e == null ? void 0 : e.tags) == null ? void 0 : i.join(", ")) || "", t.fields.protocol = (e == null ? void 0 : e.protocol) || "http", t.fields.path = (e == null ? void 0 : e.path) || "", t.fields.read_timeout = e != null && e.read_timeout || (e == null ? void 0 : e.read_timeout) === 0 ? e == null ? void 0 : e.read_timeout : 6e4, t.fields.retries = e != null && e.retries || (e == null ? void 0 : e.retries) === 0 ? e == null ? void 0 : e.retries : 5, t.fields.host = (e == null ? void 0 : e.host) || "", t.fields.connect_timeout = e != null && e.connect_timeout || (e == null ? void 0 : e.connect_timeout) === 0 ? e == null ? void 0 : e.connect_timeout : 6e4, t.fields.tls_verify_enabled = (e == null ? void 0 : e.tls_verify) !== "" && (e == null ? void 0 : e.tls_verify) !== null && (e == null ? void 0 : e.tls_verify) !== void 0, t.fields.tls_verify_value = e != null && e.tls_verify ? e == null ? void 0 : e.tls_verify : !1, t.fields.ca_certificates = ((c = e == null ? void 0 : e.ca_certificates) == null ? void 0 : c.join(",")) || "", t.fields.client_certificate = ((_ = e == null ? void 0 : e.client_certificate) == null ? void 0 : _.id) || "", t.fields.write_timeout = e != null && e.write_timeout || (e == null ? void 0 : e.write_timeout) === 0 ? e == null ? void 0 : e.write_timeout : 6e4, t.fields.port = e != null && e.port || (e == null ? void 0 : e.port) === 0 ? e == null ? void 0 : e.port : 80, Object.assign(b, t.fields);
1020
+ }, H = () => {
1021
+ B.push(r.config.cancelRoute);
1022
+ }, he = h(() => {
1023
+ var i, c;
1024
+ let e = `${r.config.apiBaseUrl}${ae.form[r.config.app].validate}`;
1025
+ return r.config.app === "konnect" ? e = e.replace(/{controlPlaneId}/gi, ((i = r.config) == null ? void 0 : i.controlPlaneId) || "") : r.config.app === "kongManager" && (e = e.replace(/\/{workspace}/gi, (c = r.config) != null && c.workspace ? `/${r.config.workspace}` : "")), e = e.replace(/{id}/gi, r.gatewayServiceId), e;
1026
+ }), f = h(() => {
1027
+ var i, c;
1028
+ let e = `${r.config.apiBaseUrl}${ae.form[r.config.app][G.value]}`;
1029
+ return r.config.app === "konnect" ? e = e.replace(/{controlPlaneId}/gi, ((i = r.config) == null ? void 0 : i.controlPlaneId) || "") : r.config.app === "kongManager" && (e = e.replace(/\/{workspace}/gi, (c = r.config) != null && c.workspace ? `/${r.config.workspace}` : "")), e = e.replace(/{id}/gi, r.gatewayServiceId), e;
1030
+ }), v = (e) => {
907
1031
  let i = "";
908
- t.url && (i = new URL(t.url).protocol), (["https", "wss", "tls"].includes(t.protocol) || ["https", "wss", "tls"].includes(i)) && (t.tls_verify = t.tls_verify_enabled ? t.tls_verify_value : null), delete t.tls_verify_enabled, delete t.tls_verify_value;
909
- }, q = b(() => {
910
- var i, v, R, S;
911
- const t = {
912
- name: e.fields.name || null,
913
- tags: e.fields.tags ? (R = (v = (i = e.fields.tags) == null ? void 0 : i.split(",")) == null ? void 0 : v.map((w) => String(w || "").trim())) == null ? void 0 : R.filter((w) => w !== "") : null,
914
- protocol: e.fields.protocol,
915
- path: e.fields.path || null,
916
- read_timeout: e.fields.read_timeout,
917
- retries: e.fields.retries,
918
- host: e.fields.host,
919
- connect_timeout: e.fields.connect_timeout,
920
- tls_verify_value: e.fields.tls_verify_value,
921
- tls_verify_enabled: e.fields.tls_verify_enabled,
922
- ca_certificates: e.fields.ca_certificates ? (S = e.fields.ca_certificates) == null ? void 0 : S.split(",").filter((w) => w !== "") : null,
923
- client_certificate: e.fields.client_certificate ? { id: e.fields.client_certificate } : null,
924
- write_timeout: e.fields.write_timeout,
925
- port: e.fields.port,
926
- url: e.fields.url
1032
+ e.url && (i = new URL(e.url).protocol), (["https", "wss", "tls"].includes(e.protocol) || ["https", "wss", "tls"].includes(i)) && (e.tls_verify = e.tls_verify_enabled ? e.tls_verify_value : null), delete e.tls_verify_enabled, delete e.tls_verify_value;
1033
+ }, g = h(() => {
1034
+ var i, c, _, y;
1035
+ const e = {
1036
+ name: t.fields.name || null,
1037
+ tags: t.fields.tags ? (_ = (c = (i = t.fields.tags) == null ? void 0 : i.split(",")) == null ? void 0 : c.map((S) => String(S || "").trim())) == null ? void 0 : _.filter((S) => S !== "") : null,
1038
+ protocol: t.fields.protocol,
1039
+ path: t.fields.path || null,
1040
+ read_timeout: t.fields.read_timeout,
1041
+ retries: t.fields.retries,
1042
+ host: t.fields.host,
1043
+ connect_timeout: t.fields.connect_timeout,
1044
+ tls_verify_value: t.fields.tls_verify_value,
1045
+ tls_verify_enabled: t.fields.tls_verify_enabled,
1046
+ ca_certificates: t.fields.ca_certificates ? (y = t.fields.ca_certificates) == null ? void 0 : y.split(",").filter((S) => S !== "") : null,
1047
+ client_certificate: t.fields.client_certificate ? { id: t.fields.client_certificate } : null,
1048
+ write_timeout: t.fields.write_timeout,
1049
+ port: t.fields.port,
1050
+ url: t.fields.url
927
1051
  };
928
- return e.fields.client_certificate && ["https", "wss", "tls"].includes(e.fields.protocol) && (t.client_certificate = { id: e.fields.client_certificate }), e.fields.tls_verify_enabled && ["https", "wss", "tls"].includes(e.fields.protocol) && (t.tls_verify = e.fields.tls_verify_value), X.value || (t.path = null), N.value === "create" ? _.value === "url" ? (delete t.protocol, delete t.host, delete t.path, r.config.app === g.Konnect && delete t.port) : delete t.url : N.value === "edit" && delete t.url, t;
929
- }), H = async () => {
930
- var t, i, v, R;
1052
+ return t.fields.client_certificate && ["https", "wss", "tls"].includes(t.fields.protocol) && (e.client_certificate = { id: t.fields.client_certificate }), t.fields.tls_verify_enabled && ["https", "wss", "tls"].includes(t.fields.protocol) && (e.tls_verify = t.fields.tls_verify_value), Z.value || (e.path = null), G.value === "create" ? F.value === "url" ? (delete e.protocol, delete e.host, delete e.path, r.config.app === "konnect" && delete e.port) : delete e.url : G.value === "edit" && delete e.url, e;
1053
+ }), V = async () => {
1054
+ var e, i, c, _;
931
1055
  try {
932
- e.isReadonly = !0, E();
933
- const S = q.value;
934
- B(S);
935
- let w;
936
- if (await V.post(Se.value, S), N.value === "create" ? w = await V.post(oe.value, S) : N.value === "edit" && (w = ((t = r.config) == null ? void 0 : t.app) === g.Konnect ? await V.put(oe.value, S) : await V.patch(oe.value, S)), w) {
937
- const { data: o } = w;
938
- e.fields.name = (o == null ? void 0 : o.name) || "", e.fields.port = o.port || ee.getPortFromProtocol(o.protocol), e.fields.protocol = (o == null ? void 0 : o.protocol) || "http", e.fields.host = (o == null ? void 0 : o.host) || "", e.fields.path = (o == null ? void 0 : o.path) || "", e.fields.url = (o == null ? void 0 : o.url) || "", e.fields.retries = o != null && o.retries || (o == null ? void 0 : o.retries) === 0 ? o == null ? void 0 : o.retries : 5, e.fields.connect_timeout = o != null && o.connect_timeout || (o == null ? void 0 : o.connect_timeout) === 0 ? o == null ? void 0 : o.connect_timeout : 6e4, e.fields.write_timeout = o != null && o.write_timeout || (o == null ? void 0 : o.write_timeout) === 0 ? o == null ? void 0 : o.write_timeout : 6e4, e.fields.read_timeout = o != null && o.read_timeout || (o == null ? void 0 : o.read_timeout) === 0 ? o == null ? void 0 : o.read_timeout : 6e4, e.fields.client_certificate = ((i = o == null ? void 0 : o.client_certificate) == null ? void 0 : i.id) || "", e.fields.ca_certificates = (v = o == null ? void 0 : o.ca_certificates) != null && v.length ? o == null ? void 0 : o.ca_certificates.join(",") : "", e.fields.tls_verify_enabled = (o == null ? void 0 : o.tls_verify) !== "" && (o == null ? void 0 : o.tls_verify) !== null && (o == null ? void 0 : o.tls_verify) !== void 0, e.fields.tls_verify_value = e.fields.tls_verify_enabled && (o == null ? void 0 : o.tls_verify), e.fields.tags = (R = o == null ? void 0 : o.tags) != null && R.length ? o.tags.join(", ") : "", Object.assign(k, e.fields), c("update", w == null ? void 0 : w.data);
1056
+ t.isReadonly = !0, M();
1057
+ const y = g.value;
1058
+ v(y);
1059
+ let S;
1060
+ if (await D.post(he.value, y), G.value === "create" ? S = await D.post(f.value, y) : G.value === "edit" && (S = ((e = r.config) == null ? void 0 : e.app) === "konnect" ? await D.put(f.value, y) : await D.patch(f.value, y)), S) {
1061
+ const { data: l } = S;
1062
+ t.fields.name = (l == null ? void 0 : l.name) || "", t.fields.port = l.port || N.getPortFromProtocol(l.protocol), t.fields.protocol = (l == null ? void 0 : l.protocol) || "http", t.fields.host = (l == null ? void 0 : l.host) || "", t.fields.path = (l == null ? void 0 : l.path) || "", t.fields.url = (l == null ? void 0 : l.url) || "", t.fields.retries = l != null && l.retries || (l == null ? void 0 : l.retries) === 0 ? l == null ? void 0 : l.retries : 5, t.fields.connect_timeout = l != null && l.connect_timeout || (l == null ? void 0 : l.connect_timeout) === 0 ? l == null ? void 0 : l.connect_timeout : 6e4, t.fields.write_timeout = l != null && l.write_timeout || (l == null ? void 0 : l.write_timeout) === 0 ? l == null ? void 0 : l.write_timeout : 6e4, t.fields.read_timeout = l != null && l.read_timeout || (l == null ? void 0 : l.read_timeout) === 0 ? l == null ? void 0 : l.read_timeout : 6e4, t.fields.client_certificate = ((i = l == null ? void 0 : l.client_certificate) == null ? void 0 : i.id) || "", t.fields.ca_certificates = (c = l == null ? void 0 : l.ca_certificates) != null && c.length ? l == null ? void 0 : l.ca_certificates.join(",") : "", t.fields.tls_verify_enabled = (l == null ? void 0 : l.tls_verify) !== "" && (l == null ? void 0 : l.tls_verify) !== null && (l == null ? void 0 : l.tls_verify) !== void 0, t.fields.tls_verify_value = t.fields.tls_verify_enabled && (l == null ? void 0 : l.tls_verify), t.fields.tags = (_ = l == null ? void 0 : l.tags) != null && _.length ? l.tags.join(", ") : "", Object.assign(b, t.fields), n("update", S == null ? void 0 : S.data);
939
1063
  }
940
- return w;
941
- } catch (S) {
942
- e.errorMessage = U(S), c("error", S);
1064
+ return S;
1065
+ } catch (y) {
1066
+ const { fields: S, messages: l } = k(y);
1067
+ S.length && (S.forEach((z) => {
1068
+ const J = z.field;
1069
+ J === "client_certificate.id" ? t.formFieldErrors.client_certificate = z.message : J === "ca_certificates[0]" ? t.formFieldErrors.ca_certificates = z.message : Object.keys(t.formFieldErrors).includes(J) && (t.formFieldErrors = {
1070
+ ...t.formFieldErrors,
1071
+ [J]: z.message
1072
+ });
1073
+ }), t.errorMessages = l), n("error", y);
943
1074
  } finally {
944
- e.isReadonly = !1;
1075
+ t.isReadonly = !1;
945
1076
  }
946
1077
  };
947
- return Te(() => r.gatewayServiceId, () => {
948
- Object.assign(e.fields, k);
949
- }), Te(e.fields, (t) => {
950
- e.fields.port = ee.getPortFromProtocol(t.protocol, String(t.port)), c("model-updated", q.value);
951
- }), De(() => {
952
- c("model-updated", q.value);
953
- }), D({
954
- validateUrl: E,
955
- getPayload: q,
956
- saveFormData: H,
1078
+ return Ue(() => r.gatewayServiceId, () => {
1079
+ Object.assign(t.fields, b);
1080
+ }), Ue(t.fields, (e) => {
1081
+ t.fields.port = N.getPortFromProtocol(e.protocol, String(e.port)), n("model-updated", g.value);
1082
+ }), Ze(() => {
1083
+ n("model-updated", g.value), L.value || (t.fields.name = oe());
1084
+ }), P({
1085
+ validateUrl: M,
1086
+ getPayload: g,
1087
+ saveFormData: V,
957
1088
  canSubmit: le,
958
- initForm: ce
959
- }), (t, i) => {
960
- const v = F("KInput"), R = F("KLabel"), S = F("KRadio"), w = F("KSelect"), o = F("KCheckbox"), u = F("KCollapse");
961
- return I(), K("div", It, [
962
- d(l(rt), {
1089
+ initForm: _e
1090
+ }), (e, i) => {
1091
+ const c = $("KRadio"), _ = $("KButton"), y = $("KInput"), S = $("KSelect"), l = $("KCheckbox"), z = $("KCollapse"), J = $("KAlert");
1092
+ return w(), T("div", Dt, [
1093
+ d(o(gt), {
963
1094
  "can-submit": le.value,
964
- config: n.config,
965
- "edit-id": n.gatewayServiceId,
966
- "entity-type": l(Ae).GatewayService,
967
- "error-message": e.errorMessage,
968
- "fetch-url": _e.value,
969
- "form-fields": q.value,
970
- "is-readonly": e.isReadonly,
971
- onCancel: de,
972
- "onFetch:error": i[25] || (i[25] = (s) => t.$emit("error", s)),
973
- "onFetch:success": ce,
974
- onLoading: i[26] || (i[26] = (s) => t.$emit("loading", s)),
975
- onSubmit: H
1095
+ config: a.config,
1096
+ "edit-id": a.gatewayServiceId,
1097
+ "entity-type": o(We).GatewayService,
1098
+ "fetch-url": ne.value,
1099
+ "form-fields": g.value,
1100
+ "is-readonly": t.isReadonly,
1101
+ onCancel: H,
1102
+ "onFetch:error": i[25] || (i[25] = (m) => e.$emit("error", m)),
1103
+ "onFetch:success": _e,
1104
+ onLoading: i[26] || (i[26] = (m) => e.$emit("loading", m)),
1105
+ onSubmit: V
976
1106
  }, {
977
- "form-actions": f(() => [
978
- Ge(t.$slots, "form-actions", {
1107
+ "form-actions": u(() => [
1108
+ He(e.$slots, "form-actions", {
979
1109
  canSubmit: le.value,
980
- cancel: de,
981
- submit: H
1110
+ cancel: H,
1111
+ submit: V
982
1112
  }, void 0, !0)
983
1113
  ]),
984
- default: f(() => [
985
- d(l(Me), {
986
- description: l(a)("gateway_services.form.sections.general.description"),
987
- "hide-info-header": n.hideSectionsInfo,
988
- title: l(a)("gateway_services.form.sections.general.title")
989
- }, {
990
- default: f(() => [
991
- d(v, {
992
- modelValue: e.fields.name,
993
- "onUpdate:modelValue": i[0] || (i[0] = (s) => e.fields.name = s),
994
- modelModifiers: { trim: !0 },
995
- autocomplete: "off",
996
- "data-testid": "gateway-service-name-input",
997
- error: he.value,
998
- "error-message": G.value,
999
- label: l(a)("gateway_services.form.fields.name.label"),
1000
- "label-attributes": {
1001
- info: l(a)("gateway_services.form.fields.name.tooltip"),
1002
- tooltipAttributes: { maxWidth: "400" }
1003
- },
1004
- name: "name",
1005
- placeholder: l(a)("gateway_services.form.fields.name.placeholder"),
1006
- readonly: e.isReadonly,
1007
- type: "text",
1008
- onInput: Ve
1009
- }, null, 8, ["modelValue", "error", "error-message", "label", "label-attributes", "placeholder", "readonly"]),
1010
- d(v, {
1011
- modelValue: e.fields.tags,
1012
- "onUpdate:modelValue": i[1] || (i[1] = (s) => e.fields.tags = s),
1013
- modelModifiers: { trim: !0 },
1014
- autocomplete: "off",
1015
- "data-testid": "gateway-service-tags-input",
1016
- help: l(a)("gateway_services.form.fields.tags.help"),
1017
- label: l(a)("gateway_services.form.fields.tags.label"),
1018
- "label-attributes": {
1019
- info: l(a)("gateway_services.form.fields.tags.tooltip"),
1020
- tooltipAttributes: { maxWidth: "400" }
1021
- },
1022
- name: "tags",
1023
- placeholder: l(a)("gateway_services.form.fields.tags.placeholder"),
1024
- readonly: e.isReadonly,
1025
- type: "text"
1026
- }, null, 8, ["modelValue", "help", "label", "label-attributes", "placeholder", "readonly"])
1027
- ]),
1028
- _: 1
1029
- }, 8, ["description", "hide-info-header", "title"]),
1030
- d(l(Me), {
1031
- description: l(a)("gateway_services.form.sections.keys.description"),
1032
- "hide-info-header": n.hideSectionsInfo,
1033
- title: l(a)("gateway_services.form.sections.keys.title")
1114
+ default: u(() => [
1115
+ d(o(Le), {
1116
+ description: o(s)("gateway_services.form.sections.keys.description"),
1117
+ "hide-info-header": a.hideSectionsInfo,
1118
+ title: o(s)("gateway_services.form.sections.keys.title")
1034
1119
  }, {
1035
- default: f(() => [
1036
- z.value ? L("", !0) : (I(), K("div", Tt, [
1037
- C("div", Et, [
1038
- d(R, { required: "" }, {
1039
- default: f(() => [
1040
- M(h(l(a)("gateway_services.form.sections.keys.checkedGroupLabel")), 1)
1041
- ]),
1042
- _: 1
1043
- })
1044
- ]),
1045
- C("div", Pt, [
1046
- d(S, {
1047
- modelValue: _.value,
1048
- "onUpdate:modelValue": i[2] || (i[2] = (s) => _.value = s),
1120
+ default: u(() => [
1121
+ L.value ? x("", !0) : (w(), T("div", Lt, [
1122
+ E("div", Kt, [
1123
+ d(c, {
1124
+ modelValue: F.value,
1125
+ "onUpdate:modelValue": i[0] || (i[0] = (m) => F.value = m),
1126
+ card: "",
1127
+ "card-orientation": "horizontal",
1049
1128
  "data-testid": "gateway-service-url-radio",
1050
- "selected-value": ae.url,
1051
- onChange: Q
1052
- }, {
1053
- default: f(() => [
1054
- M(h(l(a)("gateway_services.form.sections.keys.urlLabel")), 1)
1055
- ]),
1056
- _: 1
1057
- }, 8, ["modelValue", "selected-value"])
1129
+ description: o(s)("gateway_services.form.sections.keys.url.description"),
1130
+ label: o(s)("gateway_services.form.sections.keys.url.label"),
1131
+ "selected-value": j.url,
1132
+ onChange: U
1133
+ }, null, 8, ["modelValue", "description", "label", "selected-value"]),
1134
+ d(c, {
1135
+ modelValue: F.value,
1136
+ "onUpdate:modelValue": i[1] || (i[1] = (m) => F.value = m),
1137
+ card: "",
1138
+ "card-orientation": "horizontal",
1139
+ "checked-group": "protocol",
1140
+ "data-testid": "gateway-service-protocol-radio",
1141
+ description: o(s)("gateway_services.form.sections.keys.protocol.description"),
1142
+ label: o(s)("gateway_services.form.sections.keys.protocol.label"),
1143
+ "selected-value": j.protocol,
1144
+ onChange: U
1145
+ }, null, 8, ["modelValue", "description", "label", "selected-value"])
1058
1146
  ]),
1059
- _.value === "url" ? (I(), K("div", Ut, [
1060
- d(v, {
1061
- modelValue: e.fields.url,
1062
- "onUpdate:modelValue": i[3] || (i[3] = (s) => e.fields.url = s),
1063
- modelModifiers: { trim: !0 },
1064
- class: "gateway-service-url-input gateway-service-form-margin-bottom",
1065
- "data-testid": "gateway-service-url-input",
1066
- label: l(a)("gateway_services.form.fields.upstream_url.label"),
1067
- "label-attributes": {
1068
- info: n.config.app === l(g).Konnect ? l(a)("gateway_services.form.fields.upstream_url.tooltip_for_konnect") : l(a)("gateway_services.form.fields.upstream_url.tooltip_for_km"),
1069
- tooltipAttributes: { maxWidth: "400" }
1070
- },
1071
- name: "url",
1072
- placeholder: l(a)("gateway_services.form.fields.upstream_url.placeholder"),
1073
- required: ""
1074
- }, null, 8, ["modelValue", "label", "label-attributes", "placeholder"])
1075
- ])) : L("", !0),
1076
- d(S, {
1077
- modelValue: _.value,
1078
- "onUpdate:modelValue": i[4] || (i[4] = (s) => _.value = s),
1079
- "checked-group": "protocol",
1080
- "data-testid": "gateway-service-protocol-radio",
1081
- "selected-value": ae.protocol,
1082
- onChange: Q
1083
- }, {
1084
- default: f(() => [
1085
- M(h(l(a)("gateway_services.form.sections.keys.checkedGroupAltLabel")), 1)
1086
- ]),
1087
- _: 1
1088
- }, 8, ["modelValue", "selected-value"])
1089
- ])),
1090
- _.value === "protocol" || z.value ? (I(), K("div", Kt, [
1091
- d(w, {
1092
- modelValue: e.fields.protocol,
1093
- "onUpdate:modelValue": i[5] || (i[5] = (s) => e.fields.protocol = s),
1094
- "data-testid": "gateway-service-protocol-select",
1095
- items: we,
1096
- label: l(a)("gateway_services.form.fields.protocol.label"),
1097
- "label-attributes": {
1098
- info: l(a)("gateway_services.form.fields.protocol.tooltip"),
1099
- tooltipAttributes: { maxWidth: "400" }
1100
- },
1101
- readonly: e.isReadonly,
1102
- required: "",
1103
- width: "100%",
1104
- onSelected: i[6] || (i[6] = (s) => J(e.fields.protocol, s))
1105
- }, null, 8, ["modelValue", "label", "label-attributes", "readonly"]),
1106
- d(v, {
1107
- modelValue: e.fields.host,
1108
- "onUpdate:modelValue": i[7] || (i[7] = (s) => e.fields.host = s),
1109
- modelModifiers: { trim: !0 },
1110
- class: "gateway-service-form-margin-top",
1111
- "data-testid": "gateway-service-host-input",
1112
- label: l(a)("gateway_services.form.fields.host.label"),
1113
- "label-attributes": {
1114
- info: l(a)("gateway_services.form.fields.host.tooltip"),
1115
- tooltipAttributes: { maxWidth: "400" }
1116
- },
1117
- name: "host",
1118
- placeholder: l(a)("gateway_services.form.fields.host.placeholder"),
1119
- required: ""
1120
- }, null, 8, ["modelValue", "label", "label-attributes", "placeholder"]),
1121
- X.value ? (I(), K("div", Rt, [
1122
- d(v, {
1123
- modelValue: e.fields.path,
1124
- "onUpdate:modelValue": i[8] || (i[8] = (s) => e.fields.path = s),
1125
- modelModifiers: { trim: !0 },
1126
- class: "gateway-service-form-margin-top",
1127
- "data-testid": "gateway-service-path-input",
1128
- label: l(a)("gateway_services.form.fields.path.label"),
1129
- "label-attributes": {
1130
- info: l(a)("gateway_services.form.fields.path.tooltip"),
1131
- tooltipAttributes: { maxWidth: "400" }
1132
- },
1133
- name: "path",
1134
- placeholder: l(a)("gateway_services.form.fields.path.placeholder")
1135
- }, null, 8, ["modelValue", "label", "label-attributes", "placeholder"])
1136
- ])) : L("", !0),
1137
- d(v, {
1138
- modelValue: e.fields.port,
1139
- "onUpdate:modelValue": [
1140
- i[9] || (i[9] = (s) => e.fields.port = s),
1141
- i[10] || (i[10] = () => {
1142
- e.fields.port = j(e.fields.port + "");
1143
- })
1144
- ],
1145
- class: "gateway-service-form-margin-top",
1146
- "data-testid": "gateway-service-port-input",
1147
- label: l(a)("gateway_services.form.fields.port.label"),
1148
- "label-attributes": {
1149
- info: l(a)("gateway_services.form.fields.port.tooltip"),
1150
- tooltipAttributes: { maxWidth: "400" }
1151
- },
1152
- name: "port",
1153
- type: "number"
1154
- }, null, 8, ["modelValue", "label", "label-attributes"])
1155
- ])) : L("", !0),
1156
- d(u, {
1157
- modelValue: $.value,
1158
- "onUpdate:modelValue": i[24] || (i[24] = (s) => $.value = s),
1159
- "data-testid": "advanced-fields-collapse",
1160
- "trigger-alignment": "leading",
1161
- "trigger-label": l(a)("gateway_services.form.sections.keys.viewAdvancedFields")
1162
- }, {
1163
- default: f(() => [
1164
- C("div", Mt, [
1165
- C("div", $t, [
1166
- d(v, {
1167
- modelValue: e.fields.retries,
1168
- "onUpdate:modelValue": [
1169
- i[11] || (i[11] = (s) => e.fields.retries = s),
1170
- i[12] || (i[12] = () => {
1171
- e.fields.retries = j(e.fields.retries + "");
1172
- })
1173
- ],
1174
- autocomplete: "off",
1175
- "data-testid": "gateway-service-retries-input",
1176
- label: l(a)("gateway_services.form.fields.retries.label"),
1177
- "label-attributes": {
1178
- info: l(a)("gateway_services.form.fields.retries.tooltip"),
1179
- tooltipAttributes: { maxWidth: "400" }
1180
- },
1181
- name: "retries",
1182
- readonly: e.isReadonly,
1183
- type: "number"
1184
- }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1185
- ]),
1186
- C("div", xt, [
1187
- d(v, {
1188
- modelValue: e.fields.connect_timeout,
1189
- "onUpdate:modelValue": [
1190
- i[13] || (i[13] = (s) => e.fields.connect_timeout = s),
1191
- i[14] || (i[14] = () => {
1192
- e.fields.connect_timeout = j(e.fields.connect_timeout + "");
1193
- })
1194
- ],
1195
- autocomplete: "off",
1196
- "data-testid": "gateway-service-connTimeout-input",
1197
- label: l(a)("gateway_services.form.fields.connect_timeout.label"),
1198
- "label-attributes": {
1199
- info: l(a)("gateway_services.form.fields.connect_timeout.tooltip"),
1200
- tooltipAttributes: { maxWidth: "400" }
1201
- },
1202
- name: "connTimeout",
1203
- readonly: e.isReadonly,
1204
- type: "number"
1205
- }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1206
- ]),
1207
- C("div", At, [
1208
- d(v, {
1209
- modelValue: e.fields.write_timeout,
1210
- "onUpdate:modelValue": [
1211
- i[15] || (i[15] = (s) => e.fields.write_timeout = s),
1212
- i[16] || (i[16] = () => {
1213
- e.fields.write_timeout = j(e.fields.write_timeout + "");
1214
- })
1215
- ],
1216
- autocomplete: "off",
1217
- "data-testid": "gateway-service-writeTimeout-input",
1218
- label: l(a)("gateway_services.form.fields.write_timeout.label"),
1147
+ d(Ae, { name: "slide-fade" }, {
1148
+ default: u(() => [
1149
+ F.value === "url" ? (w(), T("div", Ot, [
1150
+ d(y, {
1151
+ modelValue: t.fields.url,
1152
+ "onUpdate:modelValue": i[2] || (i[2] = (m) => t.fields.url = m),
1153
+ modelModifiers: { trim: !0 },
1154
+ class: "gateway-service-url-input gateway-service-form-margin-bottom",
1155
+ "data-testid": "gateway-service-url-input",
1156
+ error: ve.value("url").length > 0,
1157
+ "error-message": t.errorMessages.length <= 1 ? ve.value("url") : void 0,
1158
+ label: o(s)("gateway_services.form.fields.upstream_url.label"),
1219
1159
  "label-attributes": {
1220
- info: l(a)("gateway_services.form.fields.write_timeout.tooltip"),
1160
+ info: a.config.app === "konnect" ? o(s)("gateway_services.form.fields.upstream_url.tooltip_for_konnect") : o(s)("gateway_services.form.fields.upstream_url.tooltip_for_km"),
1221
1161
  tooltipAttributes: { maxWidth: "400" }
1222
1162
  },
1223
- name: "writeTimeout",
1224
- readonly: e.isReadonly,
1225
- type: "number"
1226
- }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1227
- ]),
1228
- C("div", Ft, [
1229
- d(v, {
1230
- modelValue: e.fields.read_timeout,
1231
- "onUpdate:modelValue": [
1232
- i[17] || (i[17] = (s) => e.fields.read_timeout = s),
1233
- i[18] || (i[18] = () => {
1234
- e.fields.read_timeout = j(e.fields.read_timeout + "");
1163
+ name: "url",
1164
+ placeholder: o(s)("gateway_services.form.fields.upstream_url.placeholder"),
1165
+ required: "",
1166
+ onInput: Y
1167
+ }, {
1168
+ after: u(() => [
1169
+ d(_, {
1170
+ appearance: "tertiary",
1171
+ size: "small"
1172
+ }, {
1173
+ default: u(() => i[27] || (i[27] = [
1174
+ K(" Try Sample API ")
1175
+ ])),
1176
+ _: 1
1235
1177
  })
1236
- ],
1237
- autocomplete: "off",
1238
- "data-testid": "gateway-service-readTimeout-input",
1239
- label: l(a)("gateway_services.form.fields.read_timeout.label"),
1240
- "label-attributes": {
1241
- info: l(a)("gateway_services.form.fields.read_timeout.tooltip"),
1242
- tooltipAttributes: { maxWidth: "400" }
1243
- },
1244
- name: "readTimeout",
1245
- readonly: e.isReadonly,
1246
- type: "number"
1247
- }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1248
- ]),
1249
- ke.value ? (I(), K("div", Bt, [
1250
- d(v, {
1251
- modelValue: e.fields.client_certificate,
1252
- "onUpdate:modelValue": i[19] || (i[19] = (s) => e.fields.client_certificate = s),
1178
+ ]),
1179
+ _: 1
1180
+ }, 8, ["modelValue", "error", "error-message", "label", "label-attributes", "placeholder"])
1181
+ ])) : x("", !0)
1182
+ ]),
1183
+ _: 1
1184
+ })
1185
+ ])),
1186
+ d(Ae, { name: "slide-fade" }, {
1187
+ default: u(() => [
1188
+ F.value === "protocol" || L.value ? (w(), T("div", Nt, [
1189
+ d(S, {
1190
+ modelValue: t.fields.protocol,
1191
+ "onUpdate:modelValue": i[3] || (i[3] = (m) => t.fields.protocol = m),
1192
+ "data-testid": "gateway-service-protocol-select",
1193
+ items: de,
1194
+ label: o(s)("gateway_services.form.fields.protocol.label"),
1195
+ "label-attributes": {
1196
+ info: o(s)("gateway_services.form.fields.protocol.tooltip"),
1197
+ tooltipAttributes: { maxWidth: "400" }
1198
+ },
1199
+ readonly: t.isReadonly,
1200
+ required: "",
1201
+ width: "100%",
1202
+ onSelected: i[4] || (i[4] = (m) => Ee(t.fields.protocol, m))
1203
+ }, null, 8, ["modelValue", "label", "label-attributes", "readonly"]),
1204
+ d(y, {
1205
+ modelValue: t.fields.host,
1206
+ "onUpdate:modelValue": i[5] || (i[5] = (m) => t.fields.host = m),
1207
+ modelModifiers: { trim: !0 },
1208
+ class: "gateway-service-form-margin-top",
1209
+ "data-testid": "gateway-service-host-input",
1210
+ error: t.formFieldErrors.host.length > 0,
1211
+ "error-message": t.formFieldErrors.host,
1212
+ label: o(s)("gateway_services.form.fields.host.label"),
1213
+ "label-attributes": {
1214
+ info: o(s)("gateway_services.form.fields.host.tooltip"),
1215
+ tooltipAttributes: { maxWidth: "400" }
1216
+ },
1217
+ name: "host",
1218
+ placeholder: o(s)("gateway_services.form.fields.host.placeholder"),
1219
+ required: "",
1220
+ onInput: o(ee)
1221
+ }, null, 8, ["modelValue", "error", "error-message", "label", "label-attributes", "placeholder", "onInput"]),
1222
+ Z.value ? (w(), T("div", qt, [
1223
+ d(y, {
1224
+ modelValue: t.fields.path,
1225
+ "onUpdate:modelValue": i[6] || (i[6] = (m) => t.fields.path = m),
1253
1226
  modelModifiers: { trim: !0 },
1254
- autocomplete: "off",
1255
- "data-testid": "gateway-service-clientCert-input",
1256
- label: l(a)("gateway_services.form.fields.client_certificate.label"),
1227
+ class: "gateway-service-form-margin-top",
1228
+ "data-testid": "gateway-service-path-input",
1229
+ error: t.formFieldErrors.path.length > 0,
1230
+ "error-message": t.formFieldErrors.path,
1231
+ label: o(s)("gateway_services.form.fields.path.label"),
1257
1232
  "label-attributes": {
1258
- info: l(a)("gateway_services.form.fields.client_certificate.tooltip"),
1233
+ info: o(s)("gateway_services.form.fields.path.tooltip"),
1259
1234
  tooltipAttributes: { maxWidth: "400" }
1260
1235
  },
1261
- name: "clientCert",
1262
- placeholder: l(a)("gateway_services.form.fields.client_certificate.placeholder"),
1263
- readonly: e.isReadonly,
1264
- type: "text"
1265
- }, null, 8, ["modelValue", "label", "label-attributes", "placeholder", "readonly"])
1266
- ])) : L("", !0),
1267
- ne.value ? (I(), K("div", Lt, [
1268
- d(v, {
1269
- modelValue: e.fields.ca_certificates,
1270
- "onUpdate:modelValue": i[20] || (i[20] = (s) => e.fields.ca_certificates = s),
1271
- modelModifiers: { trim: !0 },
1272
- autocomplete: "off",
1273
- "data-testid": "gateway-service-ca-certs-input",
1274
- label: l(a)("gateway_services.form.fields.ca_certificates.label"),
1275
- "label-attributes": { tooltipAttributes: { maxWidth: "400" } },
1276
- placeholder: l(a)("gateway_services.form.fields.ca_certificates.placeholder"),
1277
- readonly: e.isReadonly,
1278
- type: "text"
1279
- }, {
1280
- "label-tooltip": f(() => [
1281
- d(l(O), {
1282
- keypath: "gateway_services.form.fields.ca_certificates.tooltip",
1283
- scope: "global"
1236
+ name: "path",
1237
+ placeholder: o(s)("gateway_services.form.fields.path.placeholder"),
1238
+ onInput: o(ee)
1239
+ }, null, 8, ["modelValue", "error", "error-message", "label", "label-attributes", "placeholder", "onInput"])
1240
+ ])) : x("", !0),
1241
+ d(y, {
1242
+ modelValue: t.fields.port,
1243
+ "onUpdate:modelValue": [
1244
+ i[7] || (i[7] = (m) => t.fields.port = m),
1245
+ i[8] || (i[8] = () => {
1246
+ t.fields.port = q(t.fields.port + "");
1247
+ })
1248
+ ],
1249
+ class: "gateway-service-form-margin-top",
1250
+ "data-testid": "gateway-service-port-input",
1251
+ error: t.formFieldErrors.port.length > 0,
1252
+ "error-message": t.formFieldErrors.port,
1253
+ label: o(s)("gateway_services.form.fields.port.label"),
1254
+ "label-attributes": {
1255
+ info: o(s)("gateway_services.form.fields.port.tooltip"),
1256
+ tooltipAttributes: { maxWidth: "400" }
1257
+ },
1258
+ name: "port",
1259
+ type: "number",
1260
+ onInput: o(ee)
1261
+ }, null, 8, ["modelValue", "error", "error-message", "label", "label-attributes", "onInput"])
1262
+ ])) : x("", !0)
1263
+ ]),
1264
+ _: 1
1265
+ }),
1266
+ d(z, {
1267
+ modelValue: C.value,
1268
+ "onUpdate:modelValue": i[22] || (i[22] = (m) => C.value = m),
1269
+ "data-testid": "advanced-fields-collapse",
1270
+ "trigger-alignment": "leading",
1271
+ "trigger-label": o(s)("gateway_services.form.sections.keys.viewAdvancedFields")
1272
+ }, {
1273
+ default: u(() => [
1274
+ d(Ae, { name: "slide-fade" }, {
1275
+ default: u(() => [
1276
+ C.value ? x("", !0) : (w(), T("div", Wt, [
1277
+ E("div", Gt, [
1278
+ d(y, {
1279
+ modelValue: t.fields.retries,
1280
+ "onUpdate:modelValue": [
1281
+ i[9] || (i[9] = (m) => t.fields.retries = m),
1282
+ i[10] || (i[10] = () => {
1283
+ t.fields.retries = q(t.fields.retries + "");
1284
+ })
1285
+ ],
1286
+ autocomplete: "off",
1287
+ "data-testid": "gateway-service-retries-input",
1288
+ label: o(s)("gateway_services.form.fields.retries.label"),
1289
+ "label-attributes": {
1290
+ info: o(s)("gateway_services.form.fields.retries.tooltip"),
1291
+ tooltipAttributes: { maxWidth: "400" }
1292
+ },
1293
+ name: "retries",
1294
+ readonly: t.isReadonly,
1295
+ type: "number"
1296
+ }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1297
+ ]),
1298
+ E("div", jt, [
1299
+ d(y, {
1300
+ modelValue: t.fields.connect_timeout,
1301
+ "onUpdate:modelValue": [
1302
+ i[11] || (i[11] = (m) => t.fields.connect_timeout = m),
1303
+ i[12] || (i[12] = () => {
1304
+ t.fields.connect_timeout = q(t.fields.connect_timeout + "");
1305
+ })
1306
+ ],
1307
+ autocomplete: "off",
1308
+ "data-testid": "gateway-service-connTimeout-input",
1309
+ label: o(s)("gateway_services.form.fields.connect_timeout.label"),
1310
+ "label-attributes": {
1311
+ info: o(s)("gateway_services.form.fields.connect_timeout.tooltip"),
1312
+ tooltipAttributes: { maxWidth: "400" }
1313
+ },
1314
+ name: "connTimeout",
1315
+ readonly: t.isReadonly,
1316
+ type: "number"
1317
+ }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1318
+ ]),
1319
+ E("div", zt, [
1320
+ d(y, {
1321
+ modelValue: t.fields.write_timeout,
1322
+ "onUpdate:modelValue": [
1323
+ i[13] || (i[13] = (m) => t.fields.write_timeout = m),
1324
+ i[14] || (i[14] = () => {
1325
+ t.fields.write_timeout = q(t.fields.write_timeout + "");
1326
+ })
1327
+ ],
1328
+ autocomplete: "off",
1329
+ "data-testid": "gateway-service-writeTimeout-input",
1330
+ label: o(s)("gateway_services.form.fields.write_timeout.label"),
1331
+ "label-attributes": {
1332
+ info: o(s)("gateway_services.form.fields.write_timeout.tooltip"),
1333
+ tooltipAttributes: { maxWidth: "400" }
1334
+ },
1335
+ name: "writeTimeout",
1336
+ readonly: t.isReadonly,
1337
+ type: "number"
1338
+ }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1339
+ ]),
1340
+ E("div", Zt, [
1341
+ d(y, {
1342
+ modelValue: t.fields.read_timeout,
1343
+ "onUpdate:modelValue": [
1344
+ i[15] || (i[15] = (m) => t.fields.read_timeout = m),
1345
+ i[16] || (i[16] = () => {
1346
+ t.fields.read_timeout = q(t.fields.read_timeout + "");
1347
+ })
1348
+ ],
1349
+ autocomplete: "off",
1350
+ "data-testid": "gateway-service-readTimeout-input",
1351
+ label: o(s)("gateway_services.form.fields.read_timeout.label"),
1352
+ "label-attributes": {
1353
+ info: o(s)("gateway_services.form.fields.read_timeout.tooltip"),
1354
+ tooltipAttributes: { maxWidth: "400" }
1355
+ },
1356
+ name: "readTimeout",
1357
+ readonly: t.isReadonly,
1358
+ type: "number"
1359
+ }, null, 8, ["modelValue", "label", "label-attributes", "readonly"])
1360
+ ]),
1361
+ ie.value ? (w(), T("div", Ht, [
1362
+ d(y, {
1363
+ modelValue: t.fields.client_certificate,
1364
+ "onUpdate:modelValue": i[17] || (i[17] = (m) => t.fields.client_certificate = m),
1365
+ modelModifiers: { trim: !0 },
1366
+ autocomplete: "off",
1367
+ "data-testid": "gateway-service-clientCert-input",
1368
+ error: t.formFieldErrors.client_certificate.length > 0,
1369
+ label: o(s)("gateway_services.form.fields.client_certificate.label"),
1370
+ "label-attributes": {
1371
+ info: o(s)("gateway_services.form.fields.client_certificate.tooltip"),
1372
+ tooltipAttributes: { maxWidth: "400" }
1373
+ },
1374
+ name: "clientCert",
1375
+ placeholder: o(s)("gateway_services.form.fields.client_certificate.placeholder"),
1376
+ readonly: t.isReadonly,
1377
+ type: "text"
1378
+ }, null, 8, ["modelValue", "error", "label", "label-attributes", "placeholder", "readonly"])
1379
+ ])) : x("", !0),
1380
+ Fe.value ? (w(), T("div", Jt, [
1381
+ d(y, {
1382
+ modelValue: t.fields.ca_certificates,
1383
+ "onUpdate:modelValue": i[18] || (i[18] = (m) => t.fields.ca_certificates = m),
1384
+ modelModifiers: { trim: !0 },
1385
+ autocomplete: "off",
1386
+ "data-testid": "gateway-service-ca-certs-input",
1387
+ error: t.formFieldErrors.ca_certificates.length > 0,
1388
+ label: o(s)("gateway_services.form.fields.ca_certificates.label"),
1389
+ "label-attributes": { tooltipAttributes: { maxWidth: "400" } },
1390
+ placeholder: o(s)("gateway_services.form.fields.ca_certificates.placeholder"),
1391
+ readonly: t.isReadonly,
1392
+ type: "text"
1284
1393
  }, {
1285
- code1: f(() => [
1286
- C("code", null, h(l(a)("gateway_services.form.fields.ca_certificates.code1")), 1)
1287
- ]),
1288
- code2: f(() => [
1289
- C("code", null, h(l(a)("gateway_services.form.fields.ca_certificates.code2")), 1)
1394
+ "label-tooltip": u(() => [
1395
+ d(o(O), {
1396
+ keypath: "gateway_services.form.fields.ca_certificates.tooltip",
1397
+ scope: "global"
1398
+ }, {
1399
+ code1: u(() => [
1400
+ E("code", null, I(o(s)("gateway_services.form.fields.ca_certificates.code1")), 1)
1401
+ ]),
1402
+ code2: u(() => [
1403
+ E("code", null, I(o(s)("gateway_services.form.fields.ca_certificates.code2")), 1)
1404
+ ]),
1405
+ _: 1
1406
+ })
1290
1407
  ]),
1291
1408
  _: 1
1292
- })
1293
- ]),
1294
- _: 1
1295
- }, 8, ["modelValue", "label", "placeholder", "readonly"])
1296
- ])) : L("", !0),
1297
- Ce.value ? (I(), K("div", Dt, [
1298
- d(o, {
1299
- modelValue: e.fields.tls_verify_enabled,
1300
- "onUpdate:modelValue": i[21] || (i[21] = (s) => e.fields.tls_verify_enabled = s),
1301
- "data-testid": "gateway-service-tls-verify-checkbox",
1302
- description: l(a)("gateway_services.form.fields.tls_verify_enabled.help"),
1303
- label: l(a)("gateway_services.form.fields.tls_verify_enabled.label"),
1304
- "label-attributes": { tooltipAttributes: { maxWidth: "400" } }
1305
- }, {
1306
- tooltip: f(() => [
1307
- d(l(O), {
1308
- keypath: "gateway_services.form.fields.tls_verify_enabled.tooltip",
1309
- scope: "global"
1409
+ }, 8, ["modelValue", "error", "label", "placeholder", "readonly"])
1410
+ ])) : x("", !0),
1411
+ Pe.value ? (w(), T("div", Qt, [
1412
+ d(l, {
1413
+ modelValue: t.fields.tls_verify_enabled,
1414
+ "onUpdate:modelValue": i[19] || (i[19] = (m) => t.fields.tls_verify_enabled = m),
1415
+ "data-testid": "gateway-service-tls-verify-checkbox",
1416
+ description: o(s)("gateway_services.form.fields.tls_verify_enabled.help"),
1417
+ label: o(s)("gateway_services.form.fields.tls_verify_enabled.label"),
1418
+ "label-attributes": { tooltipAttributes: { maxWidth: "400" } }
1310
1419
  }, {
1311
- code1: f(() => [
1312
- C("code", null, h(l(a)("gateway_services.form.fields.tls_verify_enabled.code1")), 1)
1420
+ tooltip: u(() => [
1421
+ d(o(O), {
1422
+ keypath: "gateway_services.form.fields.tls_verify_enabled.tooltip",
1423
+ scope: "global"
1424
+ }, {
1425
+ code1: u(() => [
1426
+ E("code", null, I(o(s)("gateway_services.form.fields.tls_verify_enabled.code1")), 1)
1427
+ ]),
1428
+ _: 1
1429
+ })
1313
1430
  ]),
1314
1431
  _: 1
1315
- })
1316
- ]),
1317
- _: 1
1318
- }, 8, ["modelValue", "description", "label"]),
1319
- e.fields.tls_verify_enabled ? (I(), K("div", Gt, [
1320
- d(S, {
1321
- modelValue: e.fields.tls_verify_value,
1322
- "onUpdate:modelValue": i[22] || (i[22] = (s) => e.fields.tls_verify_value = s),
1323
- "data-testid": "gateway-service-tls-verify-true-option",
1324
- label: l(a)("gateway_services.form.fields.tls_verify_option.true.label"),
1325
- "selected-value": !0
1326
- }, null, 8, ["modelValue", "label"])
1327
- ])) : L("", !0),
1328
- e.fields.tls_verify_enabled ? (I(), K("div", qt, [
1329
- d(S, {
1330
- modelValue: e.fields.tls_verify_value,
1331
- "onUpdate:modelValue": i[23] || (i[23] = (s) => e.fields.tls_verify_value = s),
1332
- "data-testid": "gateway-service-tls-verify-false-option",
1333
- label: l(a)("gateway_services.form.fields.tls_verify_option.false.label"),
1334
- "selected-value": !1
1335
- }, null, 8, ["modelValue", "label"])
1336
- ])) : L("", !0)
1337
- ])) : L("", !0)
1338
- ])
1432
+ }, 8, ["modelValue", "description", "label"]),
1433
+ t.fields.tls_verify_enabled ? (w(), T("div", Xt, [
1434
+ d(c, {
1435
+ modelValue: t.fields.tls_verify_value,
1436
+ "onUpdate:modelValue": i[20] || (i[20] = (m) => t.fields.tls_verify_value = m),
1437
+ "data-testid": "gateway-service-tls-verify-true-option",
1438
+ label: o(s)("gateway_services.form.fields.tls_verify_option.true.label"),
1439
+ "selected-value": !0
1440
+ }, null, 8, ["modelValue", "label"])
1441
+ ])) : x("", !0),
1442
+ t.fields.tls_verify_enabled ? (w(), T("div", Yt, [
1443
+ d(c, {
1444
+ modelValue: t.fields.tls_verify_value,
1445
+ "onUpdate:modelValue": i[21] || (i[21] = (m) => t.fields.tls_verify_value = m),
1446
+ "data-testid": "gateway-service-tls-verify-false-option",
1447
+ label: o(s)("gateway_services.form.fields.tls_verify_option.false.label"),
1448
+ "selected-value": !1
1449
+ }, null, 8, ["modelValue", "label"])
1450
+ ])) : x("", !0)
1451
+ ])) : x("", !0)
1452
+ ]))
1453
+ ]),
1454
+ _: 1
1455
+ })
1339
1456
  ]),
1340
1457
  _: 1
1341
1458
  }, 8, ["modelValue", "trigger-label"])
1342
1459
  ]),
1343
1460
  _: 1
1344
- }, 8, ["description", "hide-info-header", "title"])
1461
+ }, 8, ["description", "hide-info-header", "title"]),
1462
+ d(o(Le), {
1463
+ description: o(s)("gateway_services.form.sections.general.description"),
1464
+ "hide-info-header": a.hideSectionsInfo,
1465
+ title: o(s)("gateway_services.form.sections.general.title")
1466
+ }, {
1467
+ default: u(() => [
1468
+ d(y, {
1469
+ modelValue: t.fields.name,
1470
+ "onUpdate:modelValue": i[23] || (i[23] = (m) => t.fields.name = m),
1471
+ modelModifiers: { trim: !0 },
1472
+ autocomplete: "off",
1473
+ "data-testid": "gateway-service-name-input",
1474
+ error: ce.value,
1475
+ "error-message": X.value,
1476
+ label: o(s)("gateway_services.form.fields.name.label"),
1477
+ "label-attributes": {
1478
+ info: o(s)("gateway_services.form.fields.name.tooltip"),
1479
+ tooltipAttributes: { maxWidth: "400" }
1480
+ },
1481
+ name: "name",
1482
+ placeholder: o(s)("gateway_services.form.fields.name.placeholder"),
1483
+ readonly: t.isReadonly,
1484
+ type: "text",
1485
+ onInput: ye
1486
+ }, null, 8, ["modelValue", "error", "error-message", "label", "label-attributes", "placeholder", "readonly"]),
1487
+ d(z, {
1488
+ "data-testid": "tags-collapse",
1489
+ "trigger-alignment": "leading",
1490
+ "trigger-label": o(s)("gateway_services.form.fields.tags.collapse")
1491
+ }, {
1492
+ default: u(() => [
1493
+ E("div", eo, [
1494
+ d(y, {
1495
+ modelValue: t.fields.tags,
1496
+ "onUpdate:modelValue": i[24] || (i[24] = (m) => t.fields.tags = m),
1497
+ modelModifiers: { trim: !0 },
1498
+ autocomplete: "off",
1499
+ "data-testid": "gateway-service-tags-input",
1500
+ help: o(s)("gateway_services.form.fields.tags.help"),
1501
+ label: o(s)("gateway_services.form.fields.tags.label"),
1502
+ "label-attributes": {
1503
+ info: o(s)("gateway_services.form.fields.tags.tooltip"),
1504
+ tooltipAttributes: { maxWidth: "400" }
1505
+ },
1506
+ name: "tags",
1507
+ placeholder: o(s)("gateway_services.form.fields.tags.placeholder"),
1508
+ readonly: t.isReadonly,
1509
+ type: "text"
1510
+ }, null, 8, ["modelValue", "help", "label", "label-attributes", "placeholder", "readonly"])
1511
+ ])
1512
+ ]),
1513
+ _: 1
1514
+ }, 8, ["trigger-label"])
1515
+ ]),
1516
+ _: 1
1517
+ }, 8, ["description", "hide-info-header", "title"]),
1518
+ t.errorMessages.length > 1 ? (w(), se(J, {
1519
+ key: 0,
1520
+ appearance: "danger"
1521
+ }, {
1522
+ default: u(() => [
1523
+ E("ul", to, [
1524
+ (w(!0), T(Je, null, Qe(t.errorMessages, (m) => (w(), T("li", { key: m }, I(m), 1))), 128))
1525
+ ])
1526
+ ]),
1527
+ _: 1
1528
+ })) : x("", !0)
1345
1529
  ]),
1346
1530
  _: 3
1347
- }, 8, ["can-submit", "config", "edit-id", "entity-type", "error-message", "fetch-url", "form-fields", "is-readonly"])
1531
+ }, 8, ["can-submit", "config", "edit-id", "entity-type", "fetch-url", "form-fields", "is-readonly"])
1348
1532
  ]);
1349
1533
  };
1350
1534
  }
1351
- }), Xt = /* @__PURE__ */ Fe(Ot, [["__scopeId", "data-v-861a3759"]]), Nt = { class: "kong-ui-gateway-service-entity-config-card" }, Zt = /* @__PURE__ */ Ee({
1535
+ }), uo = /* @__PURE__ */ Ge(oo, [["__scopeId", "data-v-04ecb6bd"]]), io = { class: "kong-ui-gateway-service-entity-config-card" }, fo = /* @__PURE__ */ Re({
1352
1536
  __name: "GatewayServiceConfigCard",
1353
1537
  props: {
1354
1538
  /** The base konnect or kongManger config. Pass additional config props in the shared entity component as needed. */
1355
1539
  config: {
1356
1540
  type: Object,
1357
1541
  required: !0,
1358
- validator: (n) => !(!n || ![g.Konnect, g.KongManager].includes(n == null ? void 0 : n.app) || n.app === g.Konnect && !n.controlPlaneId || n.app === g.KongManager && typeof n.workspace != "string" || !n.entityId)
1542
+ validator: (a) => !(!a || !["konnect", "kongManager"].includes(a == null ? void 0 : a.app) || a.app === "konnect" && !a.controlPlaneId || a.app === "kongManager" && typeof a.workspace != "string" || !a.entityId)
1359
1543
  },
1360
1544
  /**
1361
1545
  * External link for documentation that determines visibility of Documentation button
@@ -1374,8 +1558,8 @@ const ye = {
1374
1558
  }
1375
1559
  },
1376
1560
  emits: ["loading", "fetch:error", "fetch:success"],
1377
- setup(n) {
1378
- const D = n, { i18n: { t: p }, i18nT: c } = ye.useI18n(), r = b(() => re.form[D.config.app].edit), { getPropValue: $ } = at(), W = (a, U) => $(a, U) === !0 ? p("gateway_services.form.fields.tls_verify_option.true.display") : p("gateway_services.form.fields.tls_verify_option.false.display"), O = P({
1561
+ setup(a) {
1562
+ const P = a, { i18n: { t: p }, i18nT: n } = Ce.useI18n(), r = h(() => ae.form[P.config.app].edit), { getPropValue: C } = yt(), B = (s, A) => C(s, A) === !0 ? p("gateway_services.form.fields.tls_verify_option.true.display") : p("gateway_services.form.fields.tls_verify_option.false.display"), O = R({
1379
1563
  id: {},
1380
1564
  name: {
1381
1565
  tooltip: p("gateway_services.form.fields.name.tooltip")
@@ -1384,19 +1568,19 @@ const ye = {
1384
1568
  updated_at: {},
1385
1569
  created_at: {},
1386
1570
  protocol: {
1387
- section: pe.Basic,
1571
+ section: be.Basic,
1388
1572
  tooltip: p("gateway_services.form.fields.protocol.tooltip")
1389
1573
  },
1390
1574
  host: {
1391
- section: pe.Basic,
1575
+ section: be.Basic,
1392
1576
  tooltip: p("gateway_services.form.fields.host.tooltip")
1393
1577
  },
1394
1578
  path: {
1395
- section: pe.Basic,
1579
+ section: be.Basic,
1396
1580
  tooltip: p("gateway_services.form.fields.path.tooltip")
1397
1581
  },
1398
1582
  port: {
1399
- section: pe.Basic,
1583
+ section: be.Basic,
1400
1584
  tooltip: p("gateway_services.form.fields.port.tooltip")
1401
1585
  },
1402
1586
  tags: {
@@ -1424,7 +1608,7 @@ const ye = {
1424
1608
  tooltip: p("gateway_services.form.fields.client_certificate.tooltip")
1425
1609
  },
1426
1610
  ca_certificates: {
1427
- type: nt.BadgeTag,
1611
+ type: _t.BadgeTag,
1428
1612
  label: p("gateway_services.form.fields.ca_certificates.label"),
1429
1613
  order: 6
1430
1614
  },
@@ -1435,62 +1619,62 @@ const ye = {
1435
1619
  hidden: !0
1436
1620
  }
1437
1621
  });
1438
- return (a, U) => (I(), K("div", Nt, [
1439
- d(l(ct), {
1440
- config: n.config,
1441
- "config-card-doc": n.configCardDoc,
1622
+ return (s, A) => (w(), T("div", io, [
1623
+ d(o(ht), {
1624
+ config: a.config,
1625
+ "config-card-doc": a.configCardDoc,
1442
1626
  "config-schema": O.value,
1443
- "entity-type": l(Ae).GatewayService,
1627
+ "entity-type": o(We).GatewayService,
1444
1628
  "fetch-url": r.value,
1445
- "hide-title": n.hideTitle,
1446
- "onFetch:error": U[0] || (U[0] = (V) => a.$emit("fetch:error", V)),
1447
- "onFetch:success": U[1] || (U[1] = (V) => a.$emit("fetch:success", V)),
1448
- onLoading: U[2] || (U[2] = (V) => a.$emit("loading", V))
1629
+ "hide-title": a.hideTitle,
1630
+ "onFetch:error": A[0] || (A[0] = (k) => s.$emit("fetch:error", k)),
1631
+ "onFetch:success": A[1] || (A[1] = (k) => s.$emit("fetch:success", k)),
1632
+ onLoading: A[2] || (A[2] = (k) => s.$emit("loading", k))
1449
1633
  }, {
1450
- "enabled-label-tooltip": f(() => [
1451
- d(l(c), {
1634
+ "enabled-label-tooltip": u(() => [
1635
+ d(o(n), {
1452
1636
  keypath: "gateway_services.form.fields.enabled.tooltip",
1453
1637
  scope: "global"
1454
1638
  }, {
1455
- false: f(() => [
1456
- C("code", null, h(l(p)("gateway_services.form.fields.enabled.false")), 1)
1639
+ false: u(() => [
1640
+ E("code", null, I(o(p)("gateway_services.form.fields.enabled.false")), 1)
1457
1641
  ]),
1458
- true: f(() => [
1459
- C("code", null, h(l(p)("gateway_services.form.fields.enabled.true")), 1)
1642
+ true: u(() => [
1643
+ E("code", null, I(o(p)("gateway_services.form.fields.enabled.true")), 1)
1460
1644
  ]),
1461
1645
  _: 1
1462
1646
  })
1463
1647
  ]),
1464
- "ca_certificates-label-tooltip": f(() => [
1465
- d(l(c), {
1648
+ "ca_certificates-label-tooltip": u(() => [
1649
+ d(o(n), {
1466
1650
  keypath: "gateway_services.form.fields.ca_certificates.tooltip",
1467
1651
  scope: "global"
1468
1652
  }, {
1469
- code1: f(() => [
1470
- C("code", null, h(l(p)("gateway_services.form.fields.ca_certificates.code1")), 1)
1653
+ code1: u(() => [
1654
+ E("code", null, I(o(p)("gateway_services.form.fields.ca_certificates.code1")), 1)
1471
1655
  ]),
1472
- code2: f(() => [
1473
- C("code", null, h(l(p)("gateway_services.form.fields.ca_certificates.code2")), 1)
1656
+ code2: u(() => [
1657
+ E("code", null, I(o(p)("gateway_services.form.fields.ca_certificates.code2")), 1)
1474
1658
  ]),
1475
1659
  _: 1
1476
1660
  })
1477
1661
  ]),
1478
- "tls_verify-label-tooltip": f(() => [
1479
- d(l(c), {
1662
+ "tls_verify-label-tooltip": u(() => [
1663
+ d(o(n), {
1480
1664
  keypath: "gateway_services.form.fields.tls_verify_enabled.tooltip",
1481
1665
  scope: "global"
1482
1666
  }, {
1483
- code1: f(() => [
1484
- C("code", null, h(l(p)("gateway_services.form.fields.tls_verify_enabled.code1")), 1)
1667
+ code1: u(() => [
1668
+ E("code", null, I(o(p)("gateway_services.form.fields.tls_verify_enabled.code1")), 1)
1485
1669
  ]),
1486
1670
  _: 1
1487
1671
  })
1488
1672
  ]),
1489
- tls_verify: f((V) => [
1490
- M(h(typeof l($)("rowValue", V) == "boolean" ? W("rowValue", V) : l(p)("gateway_services.form.fields.tls_verify_option.unset.display")), 1)
1673
+ tls_verify: u((k) => [
1674
+ K(I(typeof o(C)("rowValue", k) == "boolean" ? B("rowValue", k) : o(p)("gateway_services.form.fields.tls_verify_option.unset.display")), 1)
1491
1675
  ]),
1492
- client_certificate: f((V) => [
1493
- M(h(l($)("rowValue", V) ? l($)("rowValue", V).id : "–"), 1)
1676
+ client_certificate: u((k) => [
1677
+ K(I(o(C)("rowValue", k) ? o(C)("rowValue", k).id : "–"), 1)
1494
1678
  ]),
1495
1679
  _: 1
1496
1680
  }, 8, ["config", "config-card-doc", "config-schema", "entity-type", "fetch-url", "hide-title"])
@@ -1498,7 +1682,7 @@ const ye = {
1498
1682
  }
1499
1683
  });
1500
1684
  export {
1501
- Zt as GatewayServiceConfigCard,
1502
- Xt as GatewayServiceForm,
1503
- Qt as GatewayServiceList
1685
+ fo as GatewayServiceConfigCard,
1686
+ uo as GatewayServiceForm,
1687
+ co as GatewayServiceList
1504
1688
  };