golden-logic-ui 1.0.120 → 1.0.122

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { openBlock as d, createElementBlock as u, createElementVNode as r, createCommentVNode as f, createStaticVNode as Je, inject as Ae, watch as q, effectScope as Qe, computed as M, reactive as je, resolveComponent as ae, Fragment as k, createVNode as W, normalizeClass as b, toDisplayString as g, withModifiers as U, withDirectives as E, vModelText as R, renderList as O, normalizeStyle as et, renderSlot as N, ref as C, onMounted as F, createTextVNode as w, vShow as Y, nextTick as Te, createBlock as X, resolveDynamicComponent as pe, mergeProps as se, withCtx as le, vModelDynamic as tt, provide as rt, pushScopeId as st, popScopeId as at, vModelCheckbox as nt, toHandlers as me, TransitionGroup as ot, unref as lt, resolveDirective as Me, markRaw as it } from "vue";
1
+ import { openBlock as d, createElementBlock as u, createElementVNode as r, createCommentVNode as f, createStaticVNode as Je, inject as Ae, watch as q, effectScope as Qe, computed as M, reactive as je, resolveComponent as ne, Fragment as k, createVNode as W, normalizeClass as b, toDisplayString as g, withModifiers as U, withDirectives as E, vModelText as R, renderList as O, normalizeStyle as et, renderSlot as N, ref as C, onMounted as F, createTextVNode as w, vShow as Y, nextTick as Te, createBlock as X, resolveDynamicComponent as pe, mergeProps as ae, withCtx as le, vModelDynamic as tt, provide as rt, pushScopeId as st, popScopeId as at, vModelCheckbox as nt, toHandlers as me, TransitionGroup as ot, unref as lt, resolveDirective as Me, markRaw as it } from "vue";
2
2
  const D = (e, t) => {
3
3
  const s = e.__vccOpts || e;
4
4
  for (const [n, o] of t)
@@ -1026,7 +1026,7 @@ const Ht = {
1026
1026
  "aria-hidden": "true"
1027
1027
  }, null, -1), mr = { class: "flex flex-col ml-3" }, br = { class: "text-xs" }, pr = { class: "text-xs" }, yr = { class: "flex gap-2" }, _r = ["href"], vr = ["onClick"];
1028
1028
  function xr(e, t, s, n, o, a) {
1029
- const i = ae("DeleteConfirmationModal");
1029
+ const i = ne("DeleteConfirmationModal");
1030
1030
  return d(), u(k, null, [
1031
1031
  W(i, {
1032
1032
  isOpen: o.open_delete_modal,
@@ -1390,7 +1390,7 @@ const Au = /* @__PURE__ */ D(Er, [["render", Mr]]), Lr = { class: "bg-white bord
1390
1390
  p.key === "Enter" && p.target.form && p.preventDefault();
1391
1391
  }));
1392
1392
  });
1393
- const _ = M(() => re()), $ = M(() => y()), S = M(() => {
1393
+ const _ = M(() => se()), $ = M(() => y()), S = M(() => {
1394
1394
  const p = [], v = new RegExp(h.value, "ig");
1395
1395
  for (const x of _.value) {
1396
1396
  const A = String(x.name);
@@ -1421,17 +1421,17 @@ const Au = /* @__PURE__ */ D(Er, [["render", Mr]]), Lr = { class: "bg-white bord
1421
1421
  }
1422
1422
  );
1423
1423
  }
1424
- function ne(p) {
1425
- return p !== null && p.every((v) => typeof v == "object" && v !== null);
1426
- }
1427
1424
  function Q(p) {
1425
+ return p != [] && p.every((v) => typeof v == "object" && v !== null);
1426
+ }
1427
+ function ee(p) {
1428
1428
  return p.every((v) => typeof v == "object" && v !== null);
1429
1429
  }
1430
1430
  function ue(p) {
1431
1431
  return a.value.findIndex((v) => v.id === p) !== -1;
1432
1432
  }
1433
1433
  function ce() {
1434
- a.value = re();
1434
+ a.value = se();
1435
1435
  }
1436
1436
  function fe() {
1437
1437
  a.value = [];
@@ -1439,23 +1439,23 @@ const Au = /* @__PURE__ */ D(Er, [["render", Mr]]), Lr = { class: "bg-white bord
1439
1439
  function ge(p) {
1440
1440
  p.target.id != s.field_name + "search" + m.value && p.target.id != s.field_name && !p.target.classList.contains("showOptions") && (B(), l.value = 0);
1441
1441
  }
1442
- function ee(p) {
1442
+ function te(p) {
1443
1443
  const v = `${p}${m.value}`, x = document.getElementById(v);
1444
1444
  x && x.scrollIntoView();
1445
1445
  }
1446
- function te(p) {
1446
+ function re(p) {
1447
1447
  const v = `${p}${m.value}`, x = document.getElementById(v);
1448
1448
  x && x.click();
1449
1449
  }
1450
1450
  function he(p) {
1451
- p === "ArrowDown" && l.value < S.value.length && (l.value++, ee(l.value)), p === "ArrowUp" && l.value > 1 && (l.value--, ee(l.value)), p === "Enter" && te(l.value);
1451
+ p === "ArrowDown" && l.value < S.value.length && (l.value++, te(l.value)), p === "ArrowUp" && l.value > 1 && (l.value--, te(l.value)), p === "Enter" && re(l.value);
1452
1452
  }
1453
- function re() {
1453
+ function se() {
1454
1454
  return s.options.map((p, v) => typeof p == "object" ? p : { id: p, name: p });
1455
1455
  }
1456
1456
  function y() {
1457
- if (console.log("selected.value", a.value), console.log("props.modelValue", s.modelValue), ne(a.value))
1458
- return Q(a.value) ? _.value.filter(
1457
+ if (console.log("selected.value", a.value), console.log("props.modelValue", s.modelValue), console.log("isArrayObjectNotEmpty", Q(a.value)), Q(a.value))
1458
+ return ee(a.value) ? _.value.filter(
1459
1459
  (p) => a.value.some(
1460
1460
  (v) => String(v.id) === String(p.id)
1461
1461
  )
@@ -1465,7 +1465,7 @@ const Au = /* @__PURE__ */ D(Er, [["render", Mr]]), Lr = { class: "bg-white bord
1465
1465
  )
1466
1466
  ) || [];
1467
1467
  if (s.modelValue)
1468
- return Q(s.modelValue) ? _.value.filter(
1468
+ return ee(s.modelValue) ? _.value.filter(
1469
1469
  (p) => s.modelValue.some(
1470
1470
  (v) => String(v.id) === String(p.id)
1471
1471
  )
@@ -1493,7 +1493,7 @@ const Au = /* @__PURE__ */ D(Er, [["render", Mr]]), Lr = { class: "bg-white bord
1493
1493
  return q(h, () => {
1494
1494
  S.value.length === 0 && (a.value = []);
1495
1495
  }), q(a, (p) => {
1496
- ne(a.value) && (i.value = a.value.map((v) => v.id), n("update:modelValue", i.value));
1496
+ Q(a.value) && (i.value = a.value.map((v) => v.id), n("update:modelValue", i.value));
1497
1497
  }), (p, v) => (d(), u(k, null, [
1498
1498
  e.show ? (d(), u("div", {
1499
1499
  key: 0,
@@ -1684,7 +1684,7 @@ function as(e, t, s, n, o, a) {
1684
1684
  w(" Loading... ")
1685
1685
  ]),
1686
1686
  _: 1
1687
- }, 8, ["class"])) : (d(), X(pe(s.tag), se({
1687
+ }, 8, ["class"])) : (d(), X(pe(s.tag), ae({
1688
1688
  key: 0,
1689
1689
  type: s.is_submit,
1690
1690
  disabled: s.is_disabled
@@ -2971,7 +2971,7 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
2971
2971
  const s = e, n = t, o = C(null), a = C({}), i = C(0), l = C(!1), c = C(""), h = C("");
2972
2972
  F(() => {
2973
2973
  h.value = G(), s.show || (document.body.addEventListener("click", (y) => {
2974
- ne(y);
2974
+ Q(y);
2975
2975
  }), document.addEventListener("keypress", (y) => {
2976
2976
  y.key === "Enter" && y.target.form && y.preventDefault();
2977
2977
  }));
@@ -3010,10 +3010,10 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3010
3010
  function J(y) {
3011
3011
  return y !== null && typeof y == "object" && Object.keys(y).length > 0;
3012
3012
  }
3013
- function ne(y) {
3014
- y.target.id != s.field_name + "search" + h.value && y.target.id != s.field_name && !y.target.classList.contains("showOptions") && (re(), i.value = 0);
3015
- }
3016
3013
  function Q(y) {
3014
+ y.target.id != s.field_name + "search" + h.value && y.target.id != s.field_name && !y.target.classList.contains("showOptions") && (se(), i.value = 0);
3015
+ }
3016
+ function ee(y) {
3017
3017
  const P = `${y}${h.value}`, j = document.getElementById(P);
3018
3018
  j && j.scrollIntoView();
3019
3019
  }
@@ -3022,7 +3022,7 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3022
3022
  j && j.click();
3023
3023
  }
3024
3024
  function ce(y) {
3025
- y === "ArrowDown" && i.value < $.value.length && (i.value++, Q(i.value)), y === "ArrowUp" && i.value > 1 && (i.value--, Q(i.value)), y === "Enter" && ue(i.value);
3025
+ y === "ArrowDown" && i.value < $.value.length && (i.value++, ee(i.value)), y === "ArrowUp" && i.value > 1 && (i.value--, ee(i.value)), y === "Enter" && ue(i.value);
3026
3026
  }
3027
3027
  function fe() {
3028
3028
  return s.options.map((y, P) => typeof y == "object" ? y : { id: y, name: y });
@@ -3041,10 +3041,10 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3041
3041
  (y) => String(y.id) === String(s.modelValue)
3042
3042
  ) || {};
3043
3043
  }
3044
- function ee(y) {
3044
+ function te(y) {
3045
3045
  a.value = y, l.value = !1, n("update:modelValue", a.value.id), n("selected", a.value), n("selectionChanged", a.value);
3046
3046
  }
3047
- function te() {
3047
+ function re() {
3048
3048
  s.show || (c.value = "", l.value = !0, Te(() => {
3049
3049
  var y = document.getElementById(
3050
3050
  `${s.field_name}search${h.value}`
@@ -3053,9 +3053,9 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3053
3053
  }));
3054
3054
  }
3055
3055
  function he() {
3056
- s.show || (a.value = {}, c.value = "", n("update:modelValue", ""), te());
3056
+ s.show || (a.value = {}, c.value = "", n("update:modelValue", ""), re());
3057
3057
  }
3058
- function re() {
3058
+ function se() {
3059
3059
  a.value.id || (a.value = {}, c.value = ""), n("selected", a.value), l.value = !1;
3060
3060
  }
3061
3061
  return q(c, () => {
@@ -3102,7 +3102,7 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3102
3102
  "gl-input-form-invalid": e.error_message !== ""
3103
3103
  }, "pl-8 pr-2 showOptions"]),
3104
3104
  ref: e.field_name,
3105
- onClick: P[0] || (P[0] = (v) => te()),
3105
+ onClick: P[0] || (P[0] = (v) => re()),
3106
3106
  value: (p = _.value) == null ? void 0 : p.name,
3107
3107
  placeholder: e.placeholder,
3108
3108
  autocomplete: "off",
@@ -3116,7 +3116,7 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3116
3116
  [Y, J(_.value) && e.has_cancel]
3117
3117
  ]),
3118
3118
  r("i", {
3119
- onClick: P[2] || (P[2] = (v) => !l.value && te()),
3119
+ onClick: P[2] || (P[2] = (v) => !l.value && re()),
3120
3120
  class: b([l.value ? "fa-angle-up" : "fa-angle-down", "absolute text-xl text-gray-500 cursor-pointer fas right-2 hover:text-gray-700 dark:hover:text-gray-800 showOptions"]),
3121
3121
  style: { top: "11px" }
3122
3122
  }, null, 2)
@@ -3132,7 +3132,7 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3132
3132
  ref: o.value,
3133
3133
  id: `${e.field_name}search${h.value}`,
3134
3134
  onKeydown: S,
3135
- onBlur: P[4] || (P[4] = (v) => re()),
3135
+ onBlur: P[4] || (P[4] = (v) => se()),
3136
3136
  autocomplete: "off",
3137
3137
  class: "block w-full p-2 text-sm text-gray-900 border rounded-lg outline-none border-frontend ps-10 bg-gray-50 focus:border-frontend dark:bg-gray-700 dark:border-frontenddark dark:placeholder-frontenddark dark:text-white dark:focus:border-frontenddark",
3138
3138
  placeholder: "Search ..."
@@ -3146,8 +3146,8 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3146
3146
  var A;
3147
3147
  return d(), u("div", {
3148
3148
  class: b(["relative px-2 py-2 text-xs leading-4 text-gray-700 no-underline cursor-pointer dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white", x + 1 == i.value ? "bg-gray-100 dark:bg-gray-600" : ""]),
3149
- onClick: (oe) => ee(v),
3150
- onMousedown: (oe) => ee(v),
3149
+ onClick: (oe) => te(v),
3150
+ onMousedown: (oe) => te(v),
3151
3151
  key: x,
3152
3152
  id: `${x + 1}${h.value}`
3153
3153
  }, [
@@ -3453,7 +3453,7 @@ const Uu = /* @__PURE__ */ D(ea, [["render", an], ["__scopeId", "data-v-a94f16a9
3453
3453
  })
3454
3454
  ], -1);
3455
3455
  function po(e, t, s, n, o, a) {
3456
- const i = ae("RenderlessPagination");
3456
+ const i = ne("RenderlessPagination");
3457
3457
  return d(), X(i, {
3458
3458
  data: s.data,
3459
3459
  limit: s.limit,
@@ -3470,7 +3470,7 @@ function po(e, t, s, n, o, a) {
3470
3470
  r("span", io, g(l.computed.total), 1),
3471
3471
  w(" Entries ")
3472
3472
  ])) : f("", !0),
3473
- l.computed.total > l.computed.perPage ? (d(), u("ul", se({ key: 1 }, e.$attrs, {
3473
+ l.computed.total > l.computed.perPage ? (d(), u("ul", ae({ key: 1 }, e.$attrs, {
3474
3474
  class: ["flex items-center h-8 -space-x-px text-sm", {
3475
3475
  "pagination-sm": s.size == "small",
3476
3476
  "pagination-lg": s.size == "large",
@@ -3482,7 +3482,7 @@ function po(e, t, s, n, o, a) {
3482
3482
  key: 0,
3483
3483
  class: b(["flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 ms-0 border-e-0 rounded-s-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white", { disabled: !l.computed.prevPageUrl }])
3484
3484
  }, [
3485
- r("a", se({
3485
+ r("a", ae({
3486
3486
  class: "page-link",
3487
3487
  href: "#",
3488
3488
  "aria-label": "Previous",
@@ -3498,7 +3498,7 @@ function po(e, t, s, n, o, a) {
3498
3498
  class: b(["", { active: c == l.computed.currentPage }]),
3499
3499
  key: h
3500
3500
  }, [
3501
- r("a", se({
3501
+ r("a", ae({
3502
3502
  class: "",
3503
3503
  href: "#"
3504
3504
  }, me(l.pageButtonEvents(c), !0), {
@@ -3510,7 +3510,7 @@ function po(e, t, s, n, o, a) {
3510
3510
  key: 1,
3511
3511
  class: b(["flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 rounded-e-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white", { disabled: !l.computed.nextPageUrl }])
3512
3512
  }, [
3513
- r("a", se({
3513
+ r("a", ae({
3514
3514
  class: "",
3515
3515
  href: "#",
3516
3516
  "aria-label": "Next",
@@ -3678,7 +3678,7 @@ const yo = /* @__PURE__ */ D(so, [["render", po]]), _o = {
3678
3678
  Vo
3679
3679
  ], Go = ["data-label"], Uo = { class: "overflow-auto max-h-40" }, Ro = { class: "flex items-center justify-between px-4 py-3 bg-white border-gray-200 sm:px-6 dark:text-gray-400 dark:bg-gray-800" };
3680
3680
  function Fo(e, t, s, n, o, a) {
3681
- const i = ae("dropdown"), l = ae("TailwindPagination");
3681
+ const i = ne("dropdown"), l = ne("TailwindPagination");
3682
3682
  return d(), u("div", vo, [
3683
3683
  r("div", xo, [
3684
3684
  r("div", wo, [
@@ -3919,7 +3919,7 @@ const zu = /* @__PURE__ */ D(_o, [["render", Fo]]), qo = {
3919
3919
  Ol
3920
3920
  ];
3921
3921
  function El(e, t, s, n, o, a) {
3922
- const i = ae("dropdown");
3922
+ const i = ne("dropdown");
3923
3923
  return d(), u("div", Ho, [
3924
3924
  r("div", zo, [
3925
3925
  r("div", Zo, [
@@ -1,8 +1,8 @@
1
- (function(p,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(p=typeof globalThis<"u"?globalThis:p||self,e(p.GoldenLogicUi={},p.Vue))})(this,function(p,e){"use strict";const k=(t,r)=>{const o=t.__vccOpts||t;for(const[a,l]of r)o[a]=l;return o},Be={props:["isOpen"],methods:{confirmDeletion(){this.$emit("confirm-delete")},cancelDeletion(){this.$emit("cancel-delete")}}},Ce={key:0,class:"fixed inset-0 z-50 overflow-y-auto","aria-labelledby":"modal-title",role:"dialog","aria-modal":"true"},$e={class:"flex items-end justify-center min-h-screen px-4 pt-4 pb-20 text-center sm:block sm:p-0"},Se=e.createElementVNode("div",{class:"fixed inset-0 transition-opacity bg-gray-500 bg-opacity-75","aria-hidden":"true"},null,-1),De=e.createElementVNode("span",{class:"hidden sm:inline-block sm:align-middle sm:h-screen","aria-hidden":"true"},"​",-1),Te={class:"inline-block overflow-hidden text-left align-bottom transition-all transform bg-white rounded-lg shadow-xl sm:my-8 sm:align-middle sm:max-w-lg sm:w-full"},Oe=e.createStaticVNode('<div class="px-4 pt-5 pb-4 bg-white sm:p-6 sm:pb-4"><div class="sm:flex sm:items-start"><div class="mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left"><h3 class="text-lg font-medium leading-6 text-gray-900" id="modal-title"> Confirm Deletion </h3><div class="mt-2"><p class="text-sm text-gray-500"> Are you sure you want to delete this item? This action cannot be undone. </p></div></div></div></div>',1),Pe={class:"px-4 py-3 bg-gray-50 sm:px-6 sm:flex sm:flex-row-reverse"};function je(t,r,o,a,l,n){return o.isOpen?(e.openBlock(),e.createElementBlock("div",Ce,[e.createElementVNode("div",$e,[Se,De,e.createElementVNode("div",Te,[Oe,e.createElementVNode("div",Pe,[e.createElementVNode("button",{onClick:r[0]||(r[0]=(...i)=>n.confirmDeletion&&n.confirmDeletion(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 text-base font-medium text-white bg-red-600 border border-transparent rounded-md shadow-sm hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm"}," Delete "),e.createElementVNode("button",{onClick:r[1]||(r[1]=(...i)=>n.cancelDeletion&&n.cancelDeletion(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 mt-3 text-base font-medium text-gray-700 bg-white border border-gray-300 rounded-md shadow-sm hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 sm:mt-0 sm:ml-3 sm:w-auto sm:text-sm"}," Cancel ")])])])])):e.createCommentVNode("",!0)}const z=k(Be,[["render",je]]);function Ae(){return ne().__VUE_DEVTOOLS_GLOBAL_HOOK__}function ne(){return typeof navigator<"u"&&typeof window<"u"?window:typeof globalThis<"u"?globalThis:{}}const Me=typeof Proxy=="function",Le="devtools-plugin:setup",Ie="plugin:settings:set";let O,q;function ze(){var t;return O!==void 0||(typeof window<"u"&&window.performance?(O=!0,q=window.performance):typeof globalThis<"u"&&(!((t=globalThis.perf_hooks)===null||t===void 0)&&t.performance)?(O=!0,q=globalThis.perf_hooks.performance):O=!1),O}function Ge(){return ze()?q.now():Date.now()}class Fe{constructor(r,o){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=r,this.hook=o;const a={};if(r.settings)for(const i in r.settings){const s=r.settings[i];a[i]=s.defaultValue}const l=`__vue-devtools-plugin-settings__${r.id}`;let n=Object.assign({},a);try{const i=localStorage.getItem(l),s=JSON.parse(i);Object.assign(n,s)}catch{}this.fallbacks={getSettings(){return n},setSettings(i){try{localStorage.setItem(l,JSON.stringify(i))}catch{}n=i},now(){return Ge()}},o&&o.on(Ie,(i,s)=>{i===this.plugin.id&&this.fallbacks.setSettings(s)}),this.proxiedOn=new Proxy({},{get:(i,s)=>this.target?this.target.on[s]:(...d)=>{this.onQueue.push({method:s,args:d})}}),this.proxiedTarget=new Proxy({},{get:(i,s)=>this.target?this.target[s]:s==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(s)?(...d)=>(this.targetQueue.push({method:s,args:d,resolve:()=>{}}),this.fallbacks[s](...d)):(...d)=>new Promise(c=>{this.targetQueue.push({method:s,args:d,resolve:c})})})}async setRealTarget(r){this.target=r;for(const o of this.onQueue)this.target.on[o.method](...o.args);for(const o of this.targetQueue)o.resolve(await this.target[o.method](...o.args))}}function Ue(t,r){const o=t,a=ne(),l=Ae(),n=Me&&o.enableEarlyProxy;if(l&&(a.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!n))l.emit(Le,t,r);else{const i=n?new Fe(o,l):null;(a.__VUE_DEVTOOLS_PLUGINS__=a.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:o,setupFn:r,proxy:i}),i&&r(i.proxiedTarget)}}/*!
1
+ (function(p,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(p=typeof globalThis<"u"?globalThis:p||self,e(p.GoldenLogicUi={},p.Vue))})(this,function(p,e){"use strict";const k=(t,r)=>{const o=t.__vccOpts||t;for(const[a,l]of r)o[a]=l;return o},Be={props:["isOpen"],methods:{confirmDeletion(){this.$emit("confirm-delete")},cancelDeletion(){this.$emit("cancel-delete")}}},Ce={key:0,class:"fixed inset-0 z-50 overflow-y-auto","aria-labelledby":"modal-title",role:"dialog","aria-modal":"true"},$e={class:"flex items-end justify-center min-h-screen px-4 pt-4 pb-20 text-center sm:block sm:p-0"},Se=e.createElementVNode("div",{class:"fixed inset-0 transition-opacity bg-gray-500 bg-opacity-75","aria-hidden":"true"},null,-1),De=e.createElementVNode("span",{class:"hidden sm:inline-block sm:align-middle sm:h-screen","aria-hidden":"true"},"​",-1),Te={class:"inline-block overflow-hidden text-left align-bottom transition-all transform bg-white rounded-lg shadow-xl sm:my-8 sm:align-middle sm:max-w-lg sm:w-full"},Oe=e.createStaticVNode('<div class="px-4 pt-5 pb-4 bg-white sm:p-6 sm:pb-4"><div class="sm:flex sm:items-start"><div class="mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left"><h3 class="text-lg font-medium leading-6 text-gray-900" id="modal-title"> Confirm Deletion </h3><div class="mt-2"><p class="text-sm text-gray-500"> Are you sure you want to delete this item? This action cannot be undone. </p></div></div></div></div>',1),Pe={class:"px-4 py-3 bg-gray-50 sm:px-6 sm:flex sm:flex-row-reverse"};function je(t,r,o,a,l,n){return o.isOpen?(e.openBlock(),e.createElementBlock("div",Ce,[e.createElementVNode("div",$e,[Se,De,e.createElementVNode("div",Te,[Oe,e.createElementVNode("div",Pe,[e.createElementVNode("button",{onClick:r[0]||(r[0]=(...i)=>n.confirmDeletion&&n.confirmDeletion(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 text-base font-medium text-white bg-red-600 border border-transparent rounded-md shadow-sm hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm"}," Delete "),e.createElementVNode("button",{onClick:r[1]||(r[1]=(...i)=>n.cancelDeletion&&n.cancelDeletion(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 mt-3 text-base font-medium text-gray-700 bg-white border border-gray-300 rounded-md shadow-sm hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 sm:mt-0 sm:ml-3 sm:w-auto sm:text-sm"}," Cancel ")])])])])):e.createCommentVNode("",!0)}const G=k(Be,[["render",je]]);function Ae(){return ne().__VUE_DEVTOOLS_GLOBAL_HOOK__}function ne(){return typeof navigator<"u"&&typeof window<"u"?window:typeof globalThis<"u"?globalThis:{}}const Me=typeof Proxy=="function",Le="devtools-plugin:setup",Ie="plugin:settings:set";let O,q;function ze(){var t;return O!==void 0||(typeof window<"u"&&window.performance?(O=!0,q=window.performance):typeof globalThis<"u"&&(!((t=globalThis.perf_hooks)===null||t===void 0)&&t.performance)?(O=!0,q=globalThis.perf_hooks.performance):O=!1),O}function Ge(){return ze()?q.now():Date.now()}class Fe{constructor(r,o){this.target=null,this.targetQueue=[],this.onQueue=[],this.plugin=r,this.hook=o;const a={};if(r.settings)for(const i in r.settings){const s=r.settings[i];a[i]=s.defaultValue}const l=`__vue-devtools-plugin-settings__${r.id}`;let n=Object.assign({},a);try{const i=localStorage.getItem(l),s=JSON.parse(i);Object.assign(n,s)}catch{}this.fallbacks={getSettings(){return n},setSettings(i){try{localStorage.setItem(l,JSON.stringify(i))}catch{}n=i},now(){return Ge()}},o&&o.on(Ie,(i,s)=>{i===this.plugin.id&&this.fallbacks.setSettings(s)}),this.proxiedOn=new Proxy({},{get:(i,s)=>this.target?this.target.on[s]:(...d)=>{this.onQueue.push({method:s,args:d})}}),this.proxiedTarget=new Proxy({},{get:(i,s)=>this.target?this.target[s]:s==="on"?this.proxiedOn:Object.keys(this.fallbacks).includes(s)?(...d)=>(this.targetQueue.push({method:s,args:d,resolve:()=>{}}),this.fallbacks[s](...d)):(...d)=>new Promise(c=>{this.targetQueue.push({method:s,args:d,resolve:c})})})}async setRealTarget(r){this.target=r;for(const o of this.onQueue)this.target.on[o.method](...o.args);for(const o of this.targetQueue)o.resolve(await this.target[o.method](...o.args))}}function Ue(t,r){const o=t,a=ne(),l=Ae(),n=Me&&o.enableEarlyProxy;if(l&&(a.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__||!n))l.emit(Le,t,r);else{const i=n?new Fe(o,l):null;(a.__VUE_DEVTOOLS_PLUGINS__=a.__VUE_DEVTOOLS_PLUGINS__||[]).push({pluginDescriptor:o,setupFn:r,proxy:i}),i&&r(i.proxiedTarget)}}/*!
2
2
  * vuex v4.1.0
3
3
  * (c) 2022 Evan You
4
4
  * @license MIT
5
- */var ae="store";function le(t){return t===void 0&&(t=null),e.inject(t!==null?t:ae)}function D(t,r){Object.keys(t).forEach(function(o){return r(t[o],o)})}function se(t){return t!==null&&typeof t=="object"}function Re(t){return t&&typeof t.then=="function"}function B(t,r){if(!t)throw new Error("[vuex] "+r)}function qe(t,r){return function(){return t(r)}}function ie(t,r,o){return r.indexOf(t)<0&&(o&&o.prepend?r.unshift(t):r.push(t)),function(){var a=r.indexOf(t);a>-1&&r.splice(a,1)}}function de(t,r){t._actions=Object.create(null),t._mutations=Object.create(null),t._wrappedGetters=Object.create(null),t._modulesNamespaceMap=Object.create(null);var o=t.state;G(t,o,[],t._modules.root,!0),H(t,o,r)}function H(t,r,o){var a=t._state,l=t._scope;t.getters={},t._makeLocalGettersCache=Object.create(null);var n=t._wrappedGetters,i={},s={},d=e.effectScope(!0);d.run(function(){D(n,function(c,m){i[m]=qe(c,t),s[m]=e.computed(function(){return i[m]()}),Object.defineProperty(t.getters,m,{get:function(){return s[m].value},enumerable:!0})})}),t._state=e.reactive({data:r}),t._scope=d,t.strict&&We(t),a&&o&&t._withCommit(function(){a.data=null}),l&&l.stop()}function G(t,r,o,a,l){var n=!o.length,i=t._modules.getNamespace(o);if(a.namespaced&&(t._modulesNamespaceMap[i]&&process.env.NODE_ENV!=="production"&&console.error("[vuex] duplicate namespace "+i+" for the namespaced module "+o.join("/")),t._modulesNamespaceMap[i]=a),!n&&!l){var s=Z(r,o.slice(0,-1)),d=o[o.length-1];t._withCommit(function(){process.env.NODE_ENV!=="production"&&d in s&&console.warn('[vuex] state field "'+d+'" was overridden by a module with the same name at "'+o.join(".")+'"'),s[d]=a.state})}var c=a.context=He(t,i,o);a.forEachMutation(function(m,h){var b=i+h;Ze(t,b,m,c)}),a.forEachAction(function(m,h){var b=m.root?h:i+h,_=m.handler||m;Ke(t,b,_,c)}),a.forEachGetter(function(m,h){var b=i+h;ve(t,b,m,c)}),a.forEachChild(function(m,h){G(t,r,o.concat(h),m,l)})}function He(t,r,o){var a=r==="",l={dispatch:a?t.dispatch:function(n,i,s){var d=F(n,i,s),c=d.payload,m=d.options,h=d.type;if((!m||!m.root)&&(h=r+h,process.env.NODE_ENV!=="production"&&!t._actions[h])){console.error("[vuex] unknown local action type: "+d.type+", global type: "+h);return}return t.dispatch(h,c)},commit:a?t.commit:function(n,i,s){var d=F(n,i,s),c=d.payload,m=d.options,h=d.type;if((!m||!m.root)&&(h=r+h,process.env.NODE_ENV!=="production"&&!t._mutations[h])){console.error("[vuex] unknown local mutation type: "+d.type+", global type: "+h);return}t.commit(h,c,m)}};return Object.defineProperties(l,{getters:{get:a?function(){return t.getters}:function(){return ce(t,r)}},state:{get:function(){return Z(t.state,o)}}}),l}function ce(t,r){if(!t._makeLocalGettersCache[r]){var o={},a=r.length;Object.keys(t.getters).forEach(function(l){if(l.slice(0,a)===r){var n=l.slice(a);Object.defineProperty(o,n,{get:function(){return t.getters[l]},enumerable:!0})}}),t._makeLocalGettersCache[r]=o}return t._makeLocalGettersCache[r]}function Ze(t,r,o,a){var l=t._mutations[r]||(t._mutations[r]=[]);l.push(function(i){o.call(t,a.state,i)})}function Ke(t,r,o,a){var l=t._actions[r]||(t._actions[r]=[]);l.push(function(i){var s=o.call(t,{dispatch:a.dispatch,commit:a.commit,getters:a.getters,state:a.state,rootGetters:t.getters,rootState:t.state},i);return Re(s)||(s=Promise.resolve(s)),t._devtoolHook?s.catch(function(d){throw t._devtoolHook.emit("vuex:error",d),d}):s})}function ve(t,r,o,a){if(t._wrappedGetters[r]){process.env.NODE_ENV!=="production"&&console.error("[vuex] duplicate getter key: "+r);return}t._wrappedGetters[r]=function(n){return o(a.state,a.getters,n.state,n.getters)}}function We(t){e.watch(function(){return t._state.data},function(){process.env.NODE_ENV!=="production"&&B(t._committing,"do not mutate vuex store state outside mutation handlers.")},{deep:!0,flush:"sync"})}function Z(t,r){return r.reduce(function(o,a){return o[a]},t)}function F(t,r,o){return se(t)&&t.type&&(o=r,r=t,t=t.type),process.env.NODE_ENV!=="production"&&B(typeof t=="string","expects string as the type, but found "+typeof t+"."),{type:t,payload:r,options:o}}var Ye="vuex bindings",me="vuex:mutations",K="vuex:actions",P="vuex",Xe=0;function Je(t,r){Ue({id:"org.vuejs.vuex",app:t,label:"Vuex",homepage:"https://next.vuex.vuejs.org/",logo:"https://vuejs.org/images/icons/favicon-96x96.png",packageName:"vuex",componentStateTypes:[Ye]},function(o){o.addTimelineLayer({id:me,label:"Vuex Mutations",color:ge}),o.addTimelineLayer({id:K,label:"Vuex Actions",color:ge}),o.addInspector({id:P,label:"Vuex",icon:"storage",treeFilterPlaceholder:"Filter stores..."}),o.on.getInspectorTree(function(a){if(a.app===t&&a.inspectorId===P)if(a.filter){var l=[];pe(l,r._modules.root,a.filter,""),a.rootNodes=l}else a.rootNodes=[ue(r._modules.root,"")]}),o.on.getInspectorState(function(a){if(a.app===t&&a.inspectorId===P){var l=a.nodeId;ce(r,l),a.state=tt(ot(r._modules,l),l==="root"?r.getters:r._makeLocalGettersCache,l)}}),o.on.editInspectorState(function(a){if(a.app===t&&a.inspectorId===P){var l=a.nodeId,n=a.path;l!=="root"&&(n=l.split("/").filter(Boolean).concat(n)),r._withCommit(function(){a.set(r._state.data,n,a.state.value)})}}),r.subscribe(function(a,l){var n={};a.payload&&(n.payload=a.payload),n.state=l,o.notifyComponentUpdate(),o.sendInspectorTree(P),o.sendInspectorState(P),o.addTimelineEvent({layerId:me,event:{time:Date.now(),title:a.type,data:n}})}),r.subscribeAction({before:function(a,l){var n={};a.payload&&(n.payload=a.payload),a._id=Xe++,a._time=Date.now(),n.state=l,o.addTimelineEvent({layerId:K,event:{time:a._time,title:a.type,groupId:a._id,subtitle:"start",data:n}})},after:function(a,l){var n={},i=Date.now()-a._time;n.duration={_custom:{type:"duration",display:i+"ms",tooltip:"Action duration",value:i}},a.payload&&(n.payload=a.payload),n.state=l,o.addTimelineEvent({layerId:K,event:{time:Date.now(),title:a.type,groupId:a._id,subtitle:"end",data:n}})}})})}var ge=8702998,Qe=6710886,et=16777215,fe={label:"namespaced",textColor:et,backgroundColor:Qe};function he(t){return t&&t!=="root"?t.split("/").slice(-2,-1)[0]:"Root"}function ue(t,r){return{id:r||"root",label:he(r),tags:t.namespaced?[fe]:[],children:Object.keys(t._children).map(function(o){return ue(t._children[o],r+o+"/")})}}function pe(t,r,o,a){a.includes(o)&&t.push({id:a||"root",label:a.endsWith("/")?a.slice(0,a.length-1):a||"Root",tags:r.namespaced?[fe]:[]}),Object.keys(r._children).forEach(function(l){pe(t,r._children[l],o,a+l+"/")})}function tt(t,r,o){r=o==="root"?r:r[o];var a=Object.keys(r),l={state:Object.keys(t.state).map(function(i){return{key:i,editable:!0,value:t.state[i]}})};if(a.length){var n=rt(r);l.getters=Object.keys(n).map(function(i){return{key:i.endsWith("/")?he(i):i,editable:!1,value:v(function(){return n[i]})}})}return l}function rt(t){var r={};return Object.keys(t).forEach(function(o){var a=o.split("/");if(a.length>1){var l=r,n=a.pop();a.forEach(function(i){l[i]||(l[i]={_custom:{value:{},display:i,tooltip:"Module",abstract:!0}}),l=l[i]._custom.value}),l[n]=v(function(){return t[o]})}else r[o]=v(function(){return t[o]})}),r}function ot(t,r){var o=r.split("/").filter(function(a){return a});return o.reduce(function(a,l,n){var i=a[l];if(!i)throw new Error('Missing module "'+l+'" for path "'+r+'".');return n===o.length-1?i:i._children},r==="root"?t:t.root._children)}function v(t){try{return t()}catch(r){return r}}var C=function(r,o){this.runtime=o,this._children=Object.create(null),this._rawModule=r;var a=r.state;this.state=(typeof a=="function"?a():a)||{}},ye={namespaced:{configurable:!0}};ye.namespaced.get=function(){return!!this._rawModule.namespaced},C.prototype.addChild=function(r,o){this._children[r]=o},C.prototype.removeChild=function(r){delete this._children[r]},C.prototype.getChild=function(r){return this._children[r]},C.prototype.hasChild=function(r){return r in this._children},C.prototype.update=function(r){this._rawModule.namespaced=r.namespaced,r.actions&&(this._rawModule.actions=r.actions),r.mutations&&(this._rawModule.mutations=r.mutations),r.getters&&(this._rawModule.getters=r.getters)},C.prototype.forEachChild=function(r){D(this._children,r)},C.prototype.forEachGetter=function(r){this._rawModule.getters&&D(this._rawModule.getters,r)},C.prototype.forEachAction=function(r){this._rawModule.actions&&D(this._rawModule.actions,r)},C.prototype.forEachMutation=function(r){this._rawModule.mutations&&D(this._rawModule.mutations,r)},Object.defineProperties(C.prototype,ye);var T=function(r){this.register([],r,!1)};T.prototype.get=function(r){return r.reduce(function(o,a){return o.getChild(a)},this.root)},T.prototype.getNamespace=function(r){var o=this.root;return r.reduce(function(a,l){return o=o.getChild(l),a+(o.namespaced?l+"/":"")},"")},T.prototype.update=function(r){be([],this.root,r)},T.prototype.register=function(r,o,a){var l=this;a===void 0&&(a=!0),process.env.NODE_ENV!=="production"&&xe(r,o);var n=new C(o,a);if(r.length===0)this.root=n;else{var i=this.get(r.slice(0,-1));i.addChild(r[r.length-1],n)}o.modules&&D(o.modules,function(s,d){l.register(r.concat(d),s,a)})},T.prototype.unregister=function(r){var o=this.get(r.slice(0,-1)),a=r[r.length-1],l=o.getChild(a);if(!l){process.env.NODE_ENV!=="production"&&console.warn("[vuex] trying to unregister module '"+a+"', which is not registered");return}l.runtime&&o.removeChild(a)},T.prototype.isRegistered=function(r){var o=this.get(r.slice(0,-1)),a=r[r.length-1];return o?o.hasChild(a):!1};function be(t,r,o){if(process.env.NODE_ENV!=="production"&&xe(t,o),r.update(o),o.modules)for(var a in o.modules){if(!r.getChild(a)){process.env.NODE_ENV!=="production"&&console.warn("[vuex] trying to add a new module '"+a+"' on hot reloading, manual reload is needed");return}be(t.concat(a),r.getChild(a),o.modules[a])}}var _e={assert:function(t){return typeof t=="function"},expected:"function"},nt={assert:function(t){return typeof t=="function"||typeof t=="object"&&typeof t.handler=="function"},expected:'function or object with "handler" function'},ke={getters:_e,mutations:_e,actions:nt};function xe(t,r){Object.keys(ke).forEach(function(o){if(r[o]){var a=ke[o];D(r[o],function(l,n){B(a.assert(l),at(t,o,n,l,a.expected))})}})}function at(t,r,o,a,l){var n=r+" should be "+l+' but "'+r+"."+o+'"';return t.length>0&&(n+=' in module "'+t.join(".")+'"'),n+=" is "+JSON.stringify(a)+".",n}var V=function t(r){var o=this;r===void 0&&(r={}),process.env.NODE_ENV!=="production"&&(B(typeof Promise<"u","vuex requires a Promise polyfill in this browser."),B(this instanceof t,"store must be called with the new operator."));var a=r.plugins;a===void 0&&(a=[]);var l=r.strict;l===void 0&&(l=!1);var n=r.devtools;this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new T(r),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._makeLocalGettersCache=Object.create(null),this._scope=null,this._devtools=n;var i=this,s=this,d=s.dispatch,c=s.commit;this.dispatch=function(b,_){return d.call(i,b,_)},this.commit=function(b,_,S){return c.call(i,b,_,S)},this.strict=l;var m=this._modules.root.state;G(this,m,[],this._modules.root),H(this,m),a.forEach(function(h){return h(o)})},W={state:{configurable:!0}};V.prototype.install=function(r,o){r.provide(o||ae,this),r.config.globalProperties.$store=this;var a=this._devtools!==void 0?this._devtools:process.env.NODE_ENV!=="production"||!1;a&&Je(r,this)},W.state.get=function(){return this._state.data},W.state.set=function(t){process.env.NODE_ENV!=="production"&&B(!1,"use store.replaceState() to explicit replace store state.")},V.prototype.commit=function(r,o,a){var l=this,n=F(r,o,a),i=n.type,s=n.payload,d=n.options,c={type:i,payload:s},m=this._mutations[i];if(!m){process.env.NODE_ENV!=="production"&&console.error("[vuex] unknown mutation type: "+i);return}this._withCommit(function(){m.forEach(function(b){b(s)})}),this._subscribers.slice().forEach(function(h){return h(c,l.state)}),process.env.NODE_ENV!=="production"&&d&&d.silent&&console.warn("[vuex] mutation type: "+i+". Silent option has been removed. Use the filter functionality in the vue-devtools")},V.prototype.dispatch=function(r,o){var a=this,l=F(r,o),n=l.type,i=l.payload,s={type:n,payload:i},d=this._actions[n];if(!d){process.env.NODE_ENV!=="production"&&console.error("[vuex] unknown action type: "+n);return}try{this._actionSubscribers.slice().filter(function(m){return m.before}).forEach(function(m){return m.before(s,a.state)})}catch(m){process.env.NODE_ENV!=="production"&&(console.warn("[vuex] error in before action subscribers: "),console.error(m))}var c=d.length>1?Promise.all(d.map(function(m){return m(i)})):d[0](i);return new Promise(function(m,h){c.then(function(b){try{a._actionSubscribers.filter(function(_){return _.after}).forEach(function(_){return _.after(s,a.state)})}catch(_){process.env.NODE_ENV!=="production"&&(console.warn("[vuex] error in after action subscribers: "),console.error(_))}m(b)},function(b){try{a._actionSubscribers.filter(function(_){return _.error}).forEach(function(_){return _.error(s,a.state,b)})}catch(_){process.env.NODE_ENV!=="production"&&(console.warn("[vuex] error in error action subscribers: "),console.error(_))}h(b)})})},V.prototype.subscribe=function(r,o){return ie(r,this._subscribers,o)},V.prototype.subscribeAction=function(r,o){var a=typeof r=="function"?{before:r}:r;return ie(a,this._actionSubscribers,o)},V.prototype.watch=function(r,o,a){var l=this;return process.env.NODE_ENV!=="production"&&B(typeof r=="function","store.watch only accepts a function."),e.watch(function(){return r(l.state,l.getters)},o,Object.assign({},a))},V.prototype.replaceState=function(r){var o=this;this._withCommit(function(){o._state.data=r})},V.prototype.registerModule=function(r,o,a){a===void 0&&(a={}),typeof r=="string"&&(r=[r]),process.env.NODE_ENV!=="production"&&(B(Array.isArray(r),"module path must be a string or an Array."),B(r.length>0,"cannot register the root module by using registerModule.")),this._modules.register(r,o),G(this,this.state,r,this._modules.get(r),a.preserveState),H(this,this.state)},V.prototype.unregisterModule=function(r){var o=this;typeof r=="string"&&(r=[r]),process.env.NODE_ENV!=="production"&&B(Array.isArray(r),"module path must be a string or an Array."),this._modules.unregister(r),this._withCommit(function(){var a=Z(o.state,r.slice(0,-1));delete a[r[r.length-1]]}),de(this)},V.prototype.hasModule=function(r){return typeof r=="string"&&(r=[r]),process.env.NODE_ENV!=="production"&&B(Array.isArray(r),"module path must be a string or an Array."),this._modules.isRegistered(r)},V.prototype.hotUpdate=function(r){this._modules.update(r),de(this,!0)},V.prototype._withCommit=function(r){var o=this._committing;this._committing=!0,r(),this._committing=o},Object.defineProperties(V.prototype,W);var lt=Ee(function(t,r){var o={};return process.env.NODE_ENV!=="production"&&!Y(r)&&console.error("[vuex] mapState: mapper parameter must be either an Array or an Object"),we(r).forEach(function(a){var l=a.key,n=a.val;o[l]=function(){var s=this.$store.state,d=this.$store.getters;if(t){var c=Ne(this.$store,"mapState",t);if(!c)return;s=c.context.state,d=c.context.getters}return typeof n=="function"?n.call(this,s,d):s[n]},o[l].vuex=!0}),o}),st=Ee(function(t,r){var o={};return process.env.NODE_ENV!=="production"&&!Y(r)&&console.error("[vuex] mapMutations: mapper parameter must be either an Array or an Object"),we(r).forEach(function(a){var l=a.key,n=a.val;o[l]=function(){for(var s=[],d=arguments.length;d--;)s[d]=arguments[d];var c=this.$store.commit;if(t){var m=Ne(this.$store,"mapMutations",t);if(!m)return;c=m.context.commit}return typeof n=="function"?n.apply(this,[c].concat(s)):c.apply(this.$store,[n].concat(s))}}),o});function we(t){return Y(t)?Array.isArray(t)?t.map(function(r){return{key:r,val:r}}):Object.keys(t).map(function(r){return{key:r,val:t[r]}}):[]}function Y(t){return Array.isArray(t)||se(t)}function Ee(t){return function(r,o){return typeof r!="string"?(o=r,r=""):r.charAt(r.length-1)!=="/"&&(r+="/"),t(r,o)}}function Ne(t,r,o){var a=t._modulesNamespaceMap[o];return process.env.NODE_ENV!=="production"&&!a&&console.error("[vuex] module namespace not found in "+r+"(): "+o),a}const it={components:{DeleteConfirmationModal:z},props:{is_required:{type:Boolean,default:!1},error_message:{type:String,default:""},description:{type:String,default:""},show:{type:Boolean,default:!1},has_multiple_file:{show:Boolean,default:!1},field_name:{type:String,default:""},label_name:{type:String,default:""},route_url:{type:String,default:""},model_value:{type:Array,default:[]},file_config:{type:Object,default:{}},is_enable_delete:{type:Boolean,default:!0}},emits:["uploaded"],data(){return{media_id:"",error_message_data:"",open_delete_modal:!1,files:[],uploadFileList:[],isDragging:!1}},methods:{closeDeleteModal(){this.open_delete_modal=!1},deleteAction(){axios.delete(this.route_url+"/destroyMedia/"+this.media_id).then(t=>{let r=this.uploadFileList.findIndex(o=>o.id===this.media_id);r!==-1&&this.uploadFileList.splice(r,1),this.closeDeleteModal(),this.$store.commit("notification/SHOW_NOTIFICATION",{message:"Item deleted successfully.",type:"success",duration:5e3})}).catch(t=>{console.error(t),this.is_loading=!1})},getFileName(t){return t.length>12?t.substring(0,13)+"... ."+t.split(".")[1]:t},formatFileSize(t){if(t===0)return"0 Bytes";const r=1024,o=["Bytes","KB","MB","GB","TB"],a=Math.floor(Math.log(t)/Math.log(r));return parseFloat((t/Math.pow(r,a)).toFixed(2))+" "+o[a]},onDragOver(t){t.preventDefault(),this.isDragging=!0,t.dataTransfer.dropEffect="copy"},onDragLeave(t){t.preventDefault(),this.isDragging=!1},onDrop(t){t.preventDefault(),this.isDragging=!1;const r=t.dataTransfer.files;Array.from(r).forEach(o=>{this.uploadFile(o)})},async uploadFiles(t){const r=t.target.files,o=Array.from(r).map(a=>this.uploadFile(a));await Promise.all(o),this.$emit("uploaded")},getFirstError(t,r){return t.hasOwnProperty(r)?t[r][0]:""},async uploadFile(t){return new Promise((r,o)=>{t||r();const a=new FormData;a.append("file",t),Object.entries(this.file_config).forEach(([l,n])=>{a.append(l,n)}),this.files.push({file_name:t.name,loading:0}),axios.post(this.route_url+"/media",a,{onUploadProgress:l=>{this.files[this.files.length-1].loading=Math.floor(l.loaded/l.total*100)}}).then(l=>{let n=this.files.findIndex(i=>i.file_name===t.name);n!==-1&&this.files.splice(n,1),this.uploadFileList.push({file_name:l.data.file_name,size:l.data.size,id:l.data.id,url:l.data.url}),this.error_message_data="",r()}).catch(l=>{l.response.status===422?this.error_message_data=this.getFirstError(l.response.data.errors,"file"):console.error("An error occurred:",l);let n=this.files.findIndex(i=>i.file_name===t.name);n!==-1&&this.files.splice(n,1),console.log(l),r()})})}},computed:{uploadedFileIds(){var t;return this.has_multiple_file?this.uploadFileList.map(r=>r.id):((t=this.uploadFileList[0])==null?void 0:t.id)||null}},mounted(){console.log(this.model_value),this.model_value?Array.isArray(this.model_value)?this.uploadFileList=this.model_value:this.uploadFileList=[this.model_value]:this.uploadFileList=[],this.error_message_data=this.error_message}},dt={class:"flex flex-col items-center justify-center pt-5 pb-6"},ct=["multiple"],mt=["name"],gt=[e.createElementVNode("svg",{class:"w-8 h-8 mb-4 text-gray-500 dark:text-gray-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 16"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 13h3a3 3 0 0 0 0-6h-.025A5.56 5.56 0 0 0 16 6.5 5.5 5.5 0 0 0 5.207 5.021C5.137 5.017 5.071 5 5 5a4 4 0 0 0 0 8h2.167M10 15V6m0 0L8 8m2-2 2 2"})],-1),e.createElementVNode("p",{class:"text-sm text-gray-500 dark:text-gray-400"}," Drag & drop files or browse ",-1)],ft={key:1},ht=[e.createElementVNode("p",{class:"text-sm text-gray-500 dark:text-gray-400"},"Drop files here",-1)],ut={class:"mt-2 gl-span-form-error"},pt={class:"block mt-2 mb-3 text-sm font-normal leading-5 text-gray-500"},yt={key:0,class:""},bt={class:"flex items-center justify-between p-2 mb-2 text-gray-900 rounded-lg bg-gray-50 hover:bg-gray-100 hover:shadow dark:bg-gray-600 dark:hover:bg-gray-500 dark:text-white"},_t=e.createElementVNode("i",{class:"text-3xl fas fa-file-alt"},null,-1),kt={class:"w-full ml-3"},xt={class:"flex items-center justify-between mb-1"},wt={class:"text-xs text-black dark:text-white"},Et={class:"text-xs text-black dark:text-white"},Nt={class:"w-full h-1 mb-1 bg-white rounded-full dark:bg-gray-800"},Vt={class:"overflow-x-scroll max-h-56"},Bt={class:"flex items-center justify-between p-2 mb-2 text-gray-900 rounded-lg bg-gray-50 hover:bg-gray-100 hover:shadow dark:bg-gray-600 dark:hover:bg-gray-500 dark:text-white"},Ct={class:"flex items-center"},$t=e.createElementVNode("i",{class:"text-3xl fas fa-file-alt","aria-hidden":"true"},null,-1),St={class:"flex flex-col ml-3"},Dt={class:"text-xs"},Tt={class:"text-xs"},Ot={class:"flex gap-2"},Pt=["href"],jt=["onClick"];function At(t,r,o,a,l,n){const i=e.resolveComponent("DeleteConfirmationModal");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(i,{isOpen:l.open_delete_modal,onConfirmDelete:n.deleteAction,onCancelDelete:n.closeDeleteModal},null,8,["isOpen","onConfirmDelete","onCancelDelete"]),e.createElementVNode("div",{class:e.normalizeClass([{"border-red-500 dark:border-red-500":l.error_message_data!=="","border-gray-200 dark:border-gray-700":l.error_message_data==""},"w-full p-4 bg-white border rounded-lg shadow dark:bg-gray-800"])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":l.error_message_data=="","gl-label-form-invalid":l.error_message_data!=="",required:o.is_required})},e.toDisplayString(o.label_name),3),e.createElementVNode("div",{onDragover:r[3]||(r[3]=e.withModifiers((...s)=>n.onDragOver&&n.onDragOver(...s),["prevent"])),onDragleave:r[4]||(r[4]=e.withModifiers((...s)=>n.onDragLeave&&n.onDragLeave(...s),["prevent"])),onDrop:r[5]||(r[5]=e.withModifiers((...s)=>n.onDrop&&n.onDrop(...s),["prevent"])),class:"flex flex-col items-center justify-center w-full h-40 mt-3 mb-3 border-2 border-gray-300 border-dashed rounded-lg cursor-pointer bg-gray-50 dark:hover:bg-bray-800 dark:bg-gray-700 hover:bg-gray-100 dark:border-gray-600 dark:hover:border-gray-500 dark:hover:bg-gray-600"},[e.createElementVNode("div",dt,[e.createElementVNode("input",{type:"file",ref:"file_input"+o.field_name,hidden:"",multiple:o.has_multiple_file,onChange:r[0]||(r[0]=(...s)=>n.uploadFiles&&n.uploadFiles(...s))},null,40,ct),e.withDirectives(e.createElementVNode("input",{type:"hidden",name:o.field_name,"onUpdate:modelValue":r[1]||(r[1]=s=>n.uploadedFileIds=s)},null,8,mt),[[e.vModelText,n.uploadedFileIds]]),l.isDragging?(e.openBlock(),e.createElementBlock("div",ft,ht)):(e.openBlock(),e.createElementBlock("div",{key:0,class:"flex flex-col items-center justify-center",onClick:r[2]||(r[2]=s=>t.$refs["file_input"+this.field_name].click())},gt))])],32),e.createElementVNode("span",ut,e.toDisplayString(l.error_message_data),1),e.createElementVNode("small",pt,e.toDisplayString(o.description),1),l.files.length>0?(e.openBlock(),e.createElementBlock("section",yt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.files,(s,d)=>(e.openBlock(),e.createElementBlock("li",bt,[_t,e.createElementVNode("div",kt,[e.createElementVNode("div",xt,[e.createElementVNode("span",wt,e.toDisplayString(n.getFileName(s.file_name)),1),e.createElementVNode("span",Et,e.toDisplayString(s.loading),1)]),e.createElementVNode("div",Nt,[e.createElementVNode("div",{class:"h-full bg-gray-500 rounded-full dark:bg-gray-400",style:e.normalizeStyle({width:s.loading+"%"})},null,4)])])]))),256))])):e.createCommentVNode("",!0),e.createElementVNode("section",Vt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.uploadFileList,(s,d)=>(e.openBlock(),e.createElementBlock("li",Bt,[e.createElementVNode("div",Ct,[$t,e.createElementVNode("div",St,[e.createElementVNode("span",Dt,e.toDisplayString(n.getFileName(s.file_name)),1),e.createElementVNode("span",Tt,e.toDisplayString(n.formatFileSize(s.size)),1)])]),e.createElementVNode("div",Ot,[e.createElementVNode("a",{href:s.url,target:"_blank",class:"text-lg text-blue-600 cursor-pointer dark:text-blue-400 fas fa-download"},null,8,Pt),o.is_enable_delete?(e.openBlock(),e.createElementBlock("i",{key:0,onClick:c=>{l.media_id=s.id,l.open_delete_modal=!0},class:"text-lg text-red-600 cursor-pointer dark:text-red-400 fas fa-x"},null,8,jt)):e.createCommentVNode("",!0)])]))),256))])],2)],64)}const Mt=k(it,[["render",At]]),Lt={computed:{...lt("notification",["notification"]),alertClasses(){switch(this.notification.type){case"info":return"text-blue-800 bg-blue-50 dark:bg-gray-800 dark:text-blue-400";case"error":return"text-red-800 bg-red-50 dark:bg-gray-800 dark:text-red-400";case"success":return"text-green-800 bg-green-50 dark:bg-gray-800 dark:text-green-400";case"warning":return"text-yellow-800 bg-yellow-50 dark:bg-gray-800 dark:text-yellow-300";case"dark":return"text-gray-800 bg-gray-50 dark:bg-gray-800 dark:text-gray-300";default:return""}},buttonClasses(){switch(this.notification.type){case"info":return"bg-blue-50 text-blue-500 focus:ring-blue-400 hover:bg-blue-200 dark:hover:bg-gray-700";case"error":return"bg-red-50 text-red-500 focus:ring-red-400 hover:bg-red-200 dark:hover:bg-gray-700";case"success":return"bg-green-50 text-green-500 focus:ring-green-400 hover:bg-green-200 dark:hover:bg-gray-700";case"warning":return"bg-yellow-50 text-yellow-500 focus:ring-yellow-400 hover:bg-yellow-200 dark:hover:bg-gray-700";case"dark":return"bg-gray-50 text-gray-500 focus:ring-gray-400 hover:bg-gray-200 dark:hover:bg-gray-700";default:return""}}},methods:{...st("notification",["HIDE_NOTIFICATION"]),dismiss(){this.HIDE_NOTIFICATION()}},watch:{"notification.show":function(t){t&&setTimeout(()=>{this.dismiss()},this.notification.duration)}}},It=e.createElementVNode("svg",{class:"flex-shrink-0 w-4 h-4","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5ZM9.5 4a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3ZM12 15H8a1 1 0 0 1 0-2h1v-3H8a1 1 0 0 1 0-2h2a1 1 0 0 1 1 1v4h1a1 1 0 0 1 0 2Z"})],-1),zt=e.createElementVNode("span",{class:"sr-only"},"Info",-1),Gt={class:"mr-3 text-sm font-medium ms-3"},Ft=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"w-3 h-3","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 14 14"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m1 1 6 6m0 0 6 6M7 7l6-6M7 7l-6 6"})],-1)];function Ut(t,r,o,a,l,n){return t.notification.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["fixed right-0 z-50 flex items-center p-4 m-5 mb-4 rounded-lg shadow-lg",n.alertClasses]),role:"alert"},[It,zt,e.createElementVNode("div",Gt,e.toDisplayString(t.notification.message),1),e.createElementVNode("button",{type:"button",onClick:r[0]||(r[0]=(...i)=>n.dismiss&&n.dismiss(...i)),class:e.normalizeClass(["inline-flex items-center justify-center w-6 h-6 p-1 -mx-1 -my-1 rounded-lg ms-auto focus:ring-2 hover:bg-opacity-50",n.buttonClasses]),"aria-label":"Close"},Ft,2)],2)):e.createCommentVNode("",!0)}const Rt=k(Lt,[["render",Ut]]),qt={components:{},props:{field_name:{type:String,default:""},trans_selector_name:{type:String,default:"i18n_selector"}},data(){return{locals:[],default_language:""}},methods:{getLocals(){const t={id:this.menu_id};axios.get("/admin/get_locals",{params:t}).then(r=>{this.locals=r.data.locals,this.default_language=r.data.default_language,console.log("default_language",this.default_language)}).catch(r=>{console.error(r)})}},created(){this.getLocals()},mounted(){}},Ht={class:"grid w-full gap-1 mt-5 mb-5 md:gap-0 md:grid-cols-10 language-selector"},Zt=["name","value","id","checked"],Kt=["for"];function vt(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("ul",Ht,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.locals,(i,s)=>(e.openBlock(),e.createElementBlock("li",null,[e.createElementVNode("input",{type:"radio",name:o.trans_selector_name,value:i,class:"hidden peer",id:i+"_"+o.field_name,autocomplete:"off",checked:i===l.default_language},null,8,Zt),e.createElementVNode("label",{for:i+"_"+o.field_name,class:e.normalizeClass([{"border md:!rounded-s-lg":s===0,"border md:!rounded-e-lg":s===l.locals.length-1,"border-t border-b":s!==0&&s!==l.locals.length-1},"w-full p-1 font-bold text-center text-gray-500 uppercase bg-white border-gray-200 rounded-lg cursor-pointer md:rounded-none dark:hover:text-gray-300 dark:border-gray-700 dark:peer-checked:text-blue-500 peer-checked:border-blue-600 peer-checked:text-blue-600 hover:text-gray-600 hover:bg-gray-100 dark:text-gray-400 dark:bg-gray-800 dark:hover:bg-gray-700"])},e.toDisplayString(i),11,Kt)]))),256))])}const Wt=k(qt,[["render",vt]]),Yt={class:"bg-white border rounded-lg border-stroke shadow-default dark:border-strokedark dark:bg-boxdark"},Xt={class:"px-3 py-4 border-b border-stroke dark:border-strokedark"},Jt={class:"font-semibold text-black dark:text-white"},Qt={key:0,class:"p-6"},er={__name:"GlCard",props:{class:{type:String,default:""}},setup(t){const r=t,o=e.computed(()=>r.class);return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex flex-col gap-9",o.value])},[e.createElementVNode("div",Yt,[e.createElementVNode("div",Xt,[e.createElementVNode("h3",Jt,[e.renderSlot(a.$slots,"header")])]),a.$slots.body?(e.openBlock(),e.createElementBlock("div",Qt,[e.renderSlot(a.$slots,"body")])):e.createCommentVNode("",!0)])],2))}},tr={class:"font-bold ptext-lg dark:text-white"},rr={class:"mt-3 mb-4"},or={class:"bg-blue-100 text-blue-800 text-sm font-medium mb-2 mt-2 me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},nr=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),ar=["name","value"],lr={key:0,class:"dropdown"},sr={class:"border border-gray-200 rounded-lg focus:ring-blue-500 focus:border-blue-500 dark:border-gray-600 dark:focus:ring-blue-500 dark:focus:border-blue-500"},ir={class:"relative"},dr=["onClick"],cr={class:"text-gray-700 bg-white dark:border-strokedark dark:bg-boxdark dark:text-gray-200 !border-b !border-t-0 !border-r !border-l absolute w-full z-[999999999] showOptions"},mr={class:"p-1"},gr=e.createElementVNode("label",{for:"default-search",class:"mb-2 text-sm font-medium text-gray-900 sr-only dark:text-white"},"Search",-1),fr={class:"relative"},hr=e.createElementVNode("div",{class:"absolute inset-y-0 flex items-center pointer-events-none start-0 ps-3"},[e.createElementVNode("svg",{class:"w-4 h-4 text-gray-500 dark:text-gray-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m19 19-4-4m0-7A7 7 0 1 1 1 8a7 7 0 0 1 14 0Z"})])],-1),ur=["id"],pr={class:"overflow-y-auto max-h-64"},yr=["onClick","onMousedown","id"],br={__name:"GlMultiSelectDropdown",props:{modelValue:{type:[String,Number],default:""},defaultValue:{type:[String,Number],default:""},field_name:{type:String,default:""},is_required:{type:Boolean,default:!1},has_cancel:{type:Boolean,default:!0},label_name:{type:String,default:""},options:{type:Array,required:!0,default:()=>[],note:"Options of dropdown. An array of options with id and name"},placeholder:{type:String,required:!1,default:"Please select an option",note:"Placeholder of dropdown"},maxItem:{type:Number,required:!1,default:1e4,note:"Max items showing"},show:{type:Boolean,default:!1},error_message:{type:String,default:""},description:{type:String,default:""}},emits:["update:modelValue","selected","selectionChanged"],setup(t,{emit:r}){const o=t,a=r,l=e.ref(null),n=e.ref([]),i=e.ref([]),s=e.ref(0),d=e.ref(!1),c=e.ref(""),m=e.ref("");e.onMounted(()=>{m.value=j(),o.show||(document.body.addEventListener("click",g=>{re(g)}),document.addEventListener("keypress",g=>{g.key==="Enter"&&g.target.form&&g.preventDefault()}))});const h=e.computed(()=>I()),b=e.computed(()=>f()),_=e.computed(()=>{const g=[],u=new RegExp(c.value,"ig");for(const y of h.value){const w=String(y.name);(c.value.length<1||w.match(u))&&g.length<o.maxItem&&g.push(y)}return g});function S(g){if(["ArrowLeft","ArrowUp","ArrowRight","ArrowDown","Enter"].includes(g.key)){if(["ArrowUp","ArrowDown"].includes(g.key)&&g.preventDefault(),g.key==="ArrowDown"&&o.posts==="")return;oe(g.key)}}function j(){let g=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(y){const w=(g+Math.random()*16)%16|0;return g=Math.floor(g/16),(y==="x"?w:w&3|8).toString(16)})}function U(g){return g!==null&&g.every(u=>typeof u=="object"&&u!==null)}function A(g){return g.every(u=>typeof u=="object"&&u!==null)}function Q(g){return n.value.findIndex(u=>u.id===g)!==-1}function ee(){n.value=I()}function te(){n.value=[]}function re(g){g.target.id!=o.field_name+"search"+m.value&&g.target.id!=o.field_name&&!g.target.classList.contains("showOptions")&&($(),s.value=0)}function M(g){const u=`${g}${m.value}`,y=document.getElementById(u);y&&y.scrollIntoView()}function L(g){const u=`${g}${m.value}`,y=document.getElementById(u);y&&y.click()}function oe(g){g==="ArrowDown"&&s.value<_.value.length&&(s.value++,M(s.value)),g==="ArrowUp"&&s.value>1&&(s.value--,M(s.value)),g==="Enter"&&L(s.value)}function I(){return o.options.map((g,u)=>typeof g=="object"?g:{id:g,name:g})}function f(){if(console.log("selected.value",n.value),console.log("props.modelValue",o.modelValue),U(n.value))return A(n.value)?h.value.filter(g=>n.value.some(u=>String(u.id)===String(g.id)))||[]:h.value.filter(g=>n.value.some(u=>String(u)===String(g.id)))||[];if(o.modelValue)return A(o.modelValue)?h.value.filter(g=>o.modelValue.some(u=>String(u.id)===String(g.id)))||[]:h.value.filter(g=>o.modelValue.some(u=>String(u)===String(g.id)))||[]}function x(g){let u=n.value.findIndex(y=>y.id===g.id);u!==-1?n.value.splice(u,1):n.value.push(g),d.value=!1,i.value=n.value.map(y=>y.id),a("update:modelValue",i.value),a("selected",i.value),a("selectionChanged",i.value)}function E(){o.show||(c.value="",d.value=!0,e.nextTick(()=>{var g=document.getElementById(`${o.field_name}search${m.value}`);g&&g.focus()}))}function $(){n.value.id||(n.value=[],c.value=""),a("selected",n.value),d.value=!1}return e.watch(c,()=>{_.value.length===0&&(n.value=[])}),e.watch(n,g=>{U(n.value)&&(i.value=n.value.map(u=>u.id),a("update:modelValue",i.value))}),(g,u)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",tr,e.toDisplayString(t.label_name),1),e.createElementVNode("p",rr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(y,w)=>(e.openBlock(),e.createElementBlock("span",or,e.toDisplayString(y==null?void 0:y.name),1))),256))]),nr],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(y,w)=>(e.openBlock(),e.createElementBlock("input",{type:"hidden",name:t.field_name+"[]",key:w,value:y},null,8,ar))),128)),t.options?(e.openBlock(),e.createElementBlock("div",lr,[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required})},e.toDisplayString(t.label_name),3),e.createElementVNode("div",{class:"inline-flex ml-2 rounded-md shadow-sm",role:"group"},[e.createElementVNode("button",{onClick:ee,type:"button",class:"px-4 py-0 text-sm font-medium text-gray-900 bg-transparent border border-gray-900 rounded-s-md hover:bg-gray-900 hover:text-white focus:z-10 focus:bg-gray-900 focus:text-white dark:border-white dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:bg-gray-700"}," Select all "),e.createElementVNode("button",{onClick:te,type:"button",class:"px-4 py-0 text-sm font-medium text-gray-900 bg-transparent border border-gray-900 rounded-e-md hover:bg-gray-900 hover:text-white focus:z-10 focus:bg-gray-900 focus:text-white dark:border-white dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:bg-gray-700"}," Deselect all ")]),e.createElementVNode("div",sr,[e.createElementVNode("div",ir,[e.createElementVNode("div",{class:"flex flex-wrap gap-2 pl-8 pr-2 gl-multi-dropdown showOptions",onClick:u[0]||(u[0]=y=>E())},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(y,w)=>(e.openBlock(),e.createElementBlock("span",{key:w,class:"px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded pointer-events-none dark:bg-blue-900 dark:text-blue-300"},[e.createTextVNode(e.toDisplayString(y==null?void 0:y.name)+" ",1),e.createElementVNode("i",{onClick:e.withModifiers(R=>g.clearOption(y),["stop"]),class:"cursor-pointer pointer-events-auto hover:text-red-600 dark:hover:text-red-400 fas fa-times"},null,8,dr)]))),128))]),e.createElementVNode("i",{class:e.normalizeClass([d.value?"fa-angle-up":"fa-angle-down","absolute text-xl text-gray-500 cursor-pointer fas right-2 hover:text-gray-700"]),style:{top:"11px"}},null,2)]),e.withDirectives(e.createElementVNode("div",cr,[e.createElementVNode("div",mr,[gr,e.createElementVNode("div",fr,[hr,e.withDirectives(e.createElementVNode("input",{type:"search","onUpdate:modelValue":u[1]||(u[1]=y=>c.value=y),ref:l.value,id:`${t.field_name}search${m.value}`,onKeydown:S,onBlur:u[2]||(u[2]=y=>$()),autocomplete:"off",class:"block w-full p-2 text-sm text-gray-900 border border-gray-300 rounded-lg ps-10 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500",placeholder:"Search ..."},null,40,ur),[[e.vModelText,c.value]])])]),e.createElementVNode("div",pr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(_.value,(y,w)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["block px-2 py-2 text-xs leading-4 text-gray-700 no-underline cursor-pointer dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white",w+1==s.value||Q(y.id)?"bg-gray-100 dark:bg-gray-600":""]),onClick:R=>x(y),onMousedown:R=>x(y),key:w,id:w+1},e.toDisplayString(y.name||y.id||"-"),43,yr))),128))])],512),[[e.vShow,d.value]])])])):e.createCommentVNode("",!0)],2))],64))}},_r={props:{button_type:{type:String,default:"default"},is_submit:{type:Boolean,default:!1},icon:{type:String,default:""},is_loading:{type:Boolean,default:!1},is_disabled:{type:Boolean,default:!1},tag:{type:String,default:"button"},href:{type:String,default:""}},computed:{buttonTypeClass(){switch(this.button_type){case"default":return"text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800";case"alternative":return" text-gray-900 bg-white border border-gray-200 hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-4 focus:ring-gray-100 dark:focus:ring-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700";case"dark":return"text-white bg-gray-800 hover:bg-gray-900 focus:ring-4 focus:ring-gray-300 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-700 dark:border-gray-700";case"light":return"text-gray-900 bg-white border border-gray-300 hover:bg-gray-100 focus:ring-4 focus:ring-gray-100 dark:bg-gray-800 dark:text-white dark:border-gray-600 dark:hover:bg-gray-700 dark:hover:border-gray-600 dark:focus:ring-gray-700";case"green":return" text-white bg-green-700 hover:bg-green-800 focus:ring-4 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800";case"red":return" text-white bg-red-700 hover:bg-red-800 focus:ring-4 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-900";case"yellow":return" text-white bg-yellow-400 hover:bg-yellow-500 focus:ring-4 focus:ring-yellow-300 dark:focus:ring-yellow-900";case"purple":return" text-white bg-purple-700 hover:bg-purple-800 focus:ring-4 focus:ring-purple-300 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-900";default:return""}}},methods:{}},kr=e.createElementVNode("svg",{"aria-hidden":"true",role:"status",class:"inline w-4 h-4 me-3 animate-spin",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),e.createElementVNode("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"#1C64F2"})],-1);function xr(t,r,o,a,l,n){return o.is_loading?(e.openBlock(),e.createBlock(e.resolveDynamicComponent("button"),{key:1,disabled:"",class:e.normalizeClass(`flex items-center gap-2 focus:outline-none text-sm px-2 py-2 me-2 font-medium rounded-lg ${n.buttonTypeClass}`)},{default:e.withCtx(()=>[kr,e.createTextVNode(" Loading... ")]),_:1},8,["class"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.tag),e.mergeProps({key:0,type:o.is_submit,disabled:o.is_disabled},{type:o.is_submit?"submit":void 0},{href:o.tag==="a"?o.href:void 0,class:` ${o.is_disabled?"cursor-not-allowed opacity-50":""} flex items-center gap-2 focus:outline-none text-sm px-5 py-2 me-2 font-medium rounded-lg ${n.buttonTypeClass}`}),{default:e.withCtx(()=>[o.icon?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass([o.icon,"text-base"])},null,2)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default")]),_:3},16,["type","disabled","href","class"]))}const wr=k(_r,[["render",xr]]),Er={class:"font-bold ptext-lg dark:text-white"},Nr=["name","id"],Vr=["id"],Br=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Cr=["for"],$r=e.createElementVNode("span",{class:"language-label js-language-label bg-blue-100 text-blue-800 text-xs font-medium me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},null,-1),Sr=["name","id"],Dr=["required","name","id","type"],Tr={class:"gl-span-form-error"},Or={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},Pr={__name:"GlTextareaTranslate",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:null},modelValue:{type:[String,Number],default:""},model_value_translate:{type:[String,Object],default:null},modelValueTranslate:{type:[String,Object],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},get_field_translations:{type:String,default:""},description:{type:String,default:""},translatable:{type:Object,default:null}},emits:["update:modelValue","update:modelValueTranslate","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null),i=e.ref(null);return e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus(),a.model_value&&(l("update:modelValue",a.model_value),n.value.value=a.model_value),a.model_value_translate,a.translatable&&axios.post("/admin/get_field_translations",{model:a.translatable.model,row_id:a.translatable.row_id,field:a.translatable.field}).then(s=>{i.value.value=JSON.stringify(s.data),l("update:modelValueTranslate",JSON.stringify(s.data)),console.log("input_translate",i.value.value)}).catch(s=>{console.log(s)})}),r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",Er,e.toDisplayString(t.label_name),1),e.withDirectives(e.createElementVNode("input",{type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",ref_key:"input_translate",ref:i,"onUpdate:modelValue":d[0]||(d[0]=c=>s.inputTranslateValue=c)},null,8,Nr),[[e.vModelText,s.inputTranslateValue]]),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,Vr),Br],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-translation-form":t.error_message=="","gl-label-translation-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,Cr),$r,e.createElementVNode("input",{class:"mb-4",type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",onInput:d[1]||(d[1]=c=>s.$emit("update:modelValueTranslate",c.target.value)),ref_key:"input_translate",ref:i},null,40,Sr),e.createElementVNode("textarea",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({" gl-textarea-form form-input-translation mt-4 ":t.error_message==""," gl-textarea-form-invalid form-input-translation mt-4 ":t.error_message!==""}),type:t.type,onInput:d[2]||(d[2]=c=>s.$emit("update:modelValue",c.target.value)),onKeydown:d[3]||(d[3]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,rows:"4"},`
5
+ */var ae="store";function le(t){return t===void 0&&(t=null),e.inject(t!==null?t:ae)}function D(t,r){Object.keys(t).forEach(function(o){return r(t[o],o)})}function se(t){return t!==null&&typeof t=="object"}function Re(t){return t&&typeof t.then=="function"}function B(t,r){if(!t)throw new Error("[vuex] "+r)}function qe(t,r){return function(){return t(r)}}function ie(t,r,o){return r.indexOf(t)<0&&(o&&o.prepend?r.unshift(t):r.push(t)),function(){var a=r.indexOf(t);a>-1&&r.splice(a,1)}}function de(t,r){t._actions=Object.create(null),t._mutations=Object.create(null),t._wrappedGetters=Object.create(null),t._modulesNamespaceMap=Object.create(null);var o=t.state;F(t,o,[],t._modules.root,!0),H(t,o,r)}function H(t,r,o){var a=t._state,l=t._scope;t.getters={},t._makeLocalGettersCache=Object.create(null);var n=t._wrappedGetters,i={},s={},d=e.effectScope(!0);d.run(function(){D(n,function(c,m){i[m]=qe(c,t),s[m]=e.computed(function(){return i[m]()}),Object.defineProperty(t.getters,m,{get:function(){return s[m].value},enumerable:!0})})}),t._state=e.reactive({data:r}),t._scope=d,t.strict&&We(t),a&&o&&t._withCommit(function(){a.data=null}),l&&l.stop()}function F(t,r,o,a,l){var n=!o.length,i=t._modules.getNamespace(o);if(a.namespaced&&(t._modulesNamespaceMap[i]&&process.env.NODE_ENV!=="production"&&console.error("[vuex] duplicate namespace "+i+" for the namespaced module "+o.join("/")),t._modulesNamespaceMap[i]=a),!n&&!l){var s=Z(r,o.slice(0,-1)),d=o[o.length-1];t._withCommit(function(){process.env.NODE_ENV!=="production"&&d in s&&console.warn('[vuex] state field "'+d+'" was overridden by a module with the same name at "'+o.join(".")+'"'),s[d]=a.state})}var c=a.context=He(t,i,o);a.forEachMutation(function(m,h){var b=i+h;Ze(t,b,m,c)}),a.forEachAction(function(m,h){var b=m.root?h:i+h,_=m.handler||m;Ke(t,b,_,c)}),a.forEachGetter(function(m,h){var b=i+h;ve(t,b,m,c)}),a.forEachChild(function(m,h){F(t,r,o.concat(h),m,l)})}function He(t,r,o){var a=r==="",l={dispatch:a?t.dispatch:function(n,i,s){var d=U(n,i,s),c=d.payload,m=d.options,h=d.type;if((!m||!m.root)&&(h=r+h,process.env.NODE_ENV!=="production"&&!t._actions[h])){console.error("[vuex] unknown local action type: "+d.type+", global type: "+h);return}return t.dispatch(h,c)},commit:a?t.commit:function(n,i,s){var d=U(n,i,s),c=d.payload,m=d.options,h=d.type;if((!m||!m.root)&&(h=r+h,process.env.NODE_ENV!=="production"&&!t._mutations[h])){console.error("[vuex] unknown local mutation type: "+d.type+", global type: "+h);return}t.commit(h,c,m)}};return Object.defineProperties(l,{getters:{get:a?function(){return t.getters}:function(){return ce(t,r)}},state:{get:function(){return Z(t.state,o)}}}),l}function ce(t,r){if(!t._makeLocalGettersCache[r]){var o={},a=r.length;Object.keys(t.getters).forEach(function(l){if(l.slice(0,a)===r){var n=l.slice(a);Object.defineProperty(o,n,{get:function(){return t.getters[l]},enumerable:!0})}}),t._makeLocalGettersCache[r]=o}return t._makeLocalGettersCache[r]}function Ze(t,r,o,a){var l=t._mutations[r]||(t._mutations[r]=[]);l.push(function(i){o.call(t,a.state,i)})}function Ke(t,r,o,a){var l=t._actions[r]||(t._actions[r]=[]);l.push(function(i){var s=o.call(t,{dispatch:a.dispatch,commit:a.commit,getters:a.getters,state:a.state,rootGetters:t.getters,rootState:t.state},i);return Re(s)||(s=Promise.resolve(s)),t._devtoolHook?s.catch(function(d){throw t._devtoolHook.emit("vuex:error",d),d}):s})}function ve(t,r,o,a){if(t._wrappedGetters[r]){process.env.NODE_ENV!=="production"&&console.error("[vuex] duplicate getter key: "+r);return}t._wrappedGetters[r]=function(n){return o(a.state,a.getters,n.state,n.getters)}}function We(t){e.watch(function(){return t._state.data},function(){process.env.NODE_ENV!=="production"&&B(t._committing,"do not mutate vuex store state outside mutation handlers.")},{deep:!0,flush:"sync"})}function Z(t,r){return r.reduce(function(o,a){return o[a]},t)}function U(t,r,o){return se(t)&&t.type&&(o=r,r=t,t=t.type),process.env.NODE_ENV!=="production"&&B(typeof t=="string","expects string as the type, but found "+typeof t+"."),{type:t,payload:r,options:o}}var Ye="vuex bindings",me="vuex:mutations",K="vuex:actions",P="vuex",Xe=0;function Je(t,r){Ue({id:"org.vuejs.vuex",app:t,label:"Vuex",homepage:"https://next.vuex.vuejs.org/",logo:"https://vuejs.org/images/icons/favicon-96x96.png",packageName:"vuex",componentStateTypes:[Ye]},function(o){o.addTimelineLayer({id:me,label:"Vuex Mutations",color:ge}),o.addTimelineLayer({id:K,label:"Vuex Actions",color:ge}),o.addInspector({id:P,label:"Vuex",icon:"storage",treeFilterPlaceholder:"Filter stores..."}),o.on.getInspectorTree(function(a){if(a.app===t&&a.inspectorId===P)if(a.filter){var l=[];pe(l,r._modules.root,a.filter,""),a.rootNodes=l}else a.rootNodes=[ue(r._modules.root,"")]}),o.on.getInspectorState(function(a){if(a.app===t&&a.inspectorId===P){var l=a.nodeId;ce(r,l),a.state=tt(ot(r._modules,l),l==="root"?r.getters:r._makeLocalGettersCache,l)}}),o.on.editInspectorState(function(a){if(a.app===t&&a.inspectorId===P){var l=a.nodeId,n=a.path;l!=="root"&&(n=l.split("/").filter(Boolean).concat(n)),r._withCommit(function(){a.set(r._state.data,n,a.state.value)})}}),r.subscribe(function(a,l){var n={};a.payload&&(n.payload=a.payload),n.state=l,o.notifyComponentUpdate(),o.sendInspectorTree(P),o.sendInspectorState(P),o.addTimelineEvent({layerId:me,event:{time:Date.now(),title:a.type,data:n}})}),r.subscribeAction({before:function(a,l){var n={};a.payload&&(n.payload=a.payload),a._id=Xe++,a._time=Date.now(),n.state=l,o.addTimelineEvent({layerId:K,event:{time:a._time,title:a.type,groupId:a._id,subtitle:"start",data:n}})},after:function(a,l){var n={},i=Date.now()-a._time;n.duration={_custom:{type:"duration",display:i+"ms",tooltip:"Action duration",value:i}},a.payload&&(n.payload=a.payload),n.state=l,o.addTimelineEvent({layerId:K,event:{time:Date.now(),title:a.type,groupId:a._id,subtitle:"end",data:n}})}})})}var ge=8702998,Qe=6710886,et=16777215,fe={label:"namespaced",textColor:et,backgroundColor:Qe};function he(t){return t&&t!=="root"?t.split("/").slice(-2,-1)[0]:"Root"}function ue(t,r){return{id:r||"root",label:he(r),tags:t.namespaced?[fe]:[],children:Object.keys(t._children).map(function(o){return ue(t._children[o],r+o+"/")})}}function pe(t,r,o,a){a.includes(o)&&t.push({id:a||"root",label:a.endsWith("/")?a.slice(0,a.length-1):a||"Root",tags:r.namespaced?[fe]:[]}),Object.keys(r._children).forEach(function(l){pe(t,r._children[l],o,a+l+"/")})}function tt(t,r,o){r=o==="root"?r:r[o];var a=Object.keys(r),l={state:Object.keys(t.state).map(function(i){return{key:i,editable:!0,value:t.state[i]}})};if(a.length){var n=rt(r);l.getters=Object.keys(n).map(function(i){return{key:i.endsWith("/")?he(i):i,editable:!1,value:v(function(){return n[i]})}})}return l}function rt(t){var r={};return Object.keys(t).forEach(function(o){var a=o.split("/");if(a.length>1){var l=r,n=a.pop();a.forEach(function(i){l[i]||(l[i]={_custom:{value:{},display:i,tooltip:"Module",abstract:!0}}),l=l[i]._custom.value}),l[n]=v(function(){return t[o]})}else r[o]=v(function(){return t[o]})}),r}function ot(t,r){var o=r.split("/").filter(function(a){return a});return o.reduce(function(a,l,n){var i=a[l];if(!i)throw new Error('Missing module "'+l+'" for path "'+r+'".');return n===o.length-1?i:i._children},r==="root"?t:t.root._children)}function v(t){try{return t()}catch(r){return r}}var C=function(r,o){this.runtime=o,this._children=Object.create(null),this._rawModule=r;var a=r.state;this.state=(typeof a=="function"?a():a)||{}},ye={namespaced:{configurable:!0}};ye.namespaced.get=function(){return!!this._rawModule.namespaced},C.prototype.addChild=function(r,o){this._children[r]=o},C.prototype.removeChild=function(r){delete this._children[r]},C.prototype.getChild=function(r){return this._children[r]},C.prototype.hasChild=function(r){return r in this._children},C.prototype.update=function(r){this._rawModule.namespaced=r.namespaced,r.actions&&(this._rawModule.actions=r.actions),r.mutations&&(this._rawModule.mutations=r.mutations),r.getters&&(this._rawModule.getters=r.getters)},C.prototype.forEachChild=function(r){D(this._children,r)},C.prototype.forEachGetter=function(r){this._rawModule.getters&&D(this._rawModule.getters,r)},C.prototype.forEachAction=function(r){this._rawModule.actions&&D(this._rawModule.actions,r)},C.prototype.forEachMutation=function(r){this._rawModule.mutations&&D(this._rawModule.mutations,r)},Object.defineProperties(C.prototype,ye);var T=function(r){this.register([],r,!1)};T.prototype.get=function(r){return r.reduce(function(o,a){return o.getChild(a)},this.root)},T.prototype.getNamespace=function(r){var o=this.root;return r.reduce(function(a,l){return o=o.getChild(l),a+(o.namespaced?l+"/":"")},"")},T.prototype.update=function(r){be([],this.root,r)},T.prototype.register=function(r,o,a){var l=this;a===void 0&&(a=!0),process.env.NODE_ENV!=="production"&&xe(r,o);var n=new C(o,a);if(r.length===0)this.root=n;else{var i=this.get(r.slice(0,-1));i.addChild(r[r.length-1],n)}o.modules&&D(o.modules,function(s,d){l.register(r.concat(d),s,a)})},T.prototype.unregister=function(r){var o=this.get(r.slice(0,-1)),a=r[r.length-1],l=o.getChild(a);if(!l){process.env.NODE_ENV!=="production"&&console.warn("[vuex] trying to unregister module '"+a+"', which is not registered");return}l.runtime&&o.removeChild(a)},T.prototype.isRegistered=function(r){var o=this.get(r.slice(0,-1)),a=r[r.length-1];return o?o.hasChild(a):!1};function be(t,r,o){if(process.env.NODE_ENV!=="production"&&xe(t,o),r.update(o),o.modules)for(var a in o.modules){if(!r.getChild(a)){process.env.NODE_ENV!=="production"&&console.warn("[vuex] trying to add a new module '"+a+"' on hot reloading, manual reload is needed");return}be(t.concat(a),r.getChild(a),o.modules[a])}}var _e={assert:function(t){return typeof t=="function"},expected:"function"},nt={assert:function(t){return typeof t=="function"||typeof t=="object"&&typeof t.handler=="function"},expected:'function or object with "handler" function'},ke={getters:_e,mutations:_e,actions:nt};function xe(t,r){Object.keys(ke).forEach(function(o){if(r[o]){var a=ke[o];D(r[o],function(l,n){B(a.assert(l),at(t,o,n,l,a.expected))})}})}function at(t,r,o,a,l){var n=r+" should be "+l+' but "'+r+"."+o+'"';return t.length>0&&(n+=' in module "'+t.join(".")+'"'),n+=" is "+JSON.stringify(a)+".",n}var V=function t(r){var o=this;r===void 0&&(r={}),process.env.NODE_ENV!=="production"&&(B(typeof Promise<"u","vuex requires a Promise polyfill in this browser."),B(this instanceof t,"store must be called with the new operator."));var a=r.plugins;a===void 0&&(a=[]);var l=r.strict;l===void 0&&(l=!1);var n=r.devtools;this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new T(r),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._makeLocalGettersCache=Object.create(null),this._scope=null,this._devtools=n;var i=this,s=this,d=s.dispatch,c=s.commit;this.dispatch=function(b,_){return d.call(i,b,_)},this.commit=function(b,_,S){return c.call(i,b,_,S)},this.strict=l;var m=this._modules.root.state;F(this,m,[],this._modules.root),H(this,m),a.forEach(function(h){return h(o)})},W={state:{configurable:!0}};V.prototype.install=function(r,o){r.provide(o||ae,this),r.config.globalProperties.$store=this;var a=this._devtools!==void 0?this._devtools:process.env.NODE_ENV!=="production"||!1;a&&Je(r,this)},W.state.get=function(){return this._state.data},W.state.set=function(t){process.env.NODE_ENV!=="production"&&B(!1,"use store.replaceState() to explicit replace store state.")},V.prototype.commit=function(r,o,a){var l=this,n=U(r,o,a),i=n.type,s=n.payload,d=n.options,c={type:i,payload:s},m=this._mutations[i];if(!m){process.env.NODE_ENV!=="production"&&console.error("[vuex] unknown mutation type: "+i);return}this._withCommit(function(){m.forEach(function(b){b(s)})}),this._subscribers.slice().forEach(function(h){return h(c,l.state)}),process.env.NODE_ENV!=="production"&&d&&d.silent&&console.warn("[vuex] mutation type: "+i+". Silent option has been removed. Use the filter functionality in the vue-devtools")},V.prototype.dispatch=function(r,o){var a=this,l=U(r,o),n=l.type,i=l.payload,s={type:n,payload:i},d=this._actions[n];if(!d){process.env.NODE_ENV!=="production"&&console.error("[vuex] unknown action type: "+n);return}try{this._actionSubscribers.slice().filter(function(m){return m.before}).forEach(function(m){return m.before(s,a.state)})}catch(m){process.env.NODE_ENV!=="production"&&(console.warn("[vuex] error in before action subscribers: "),console.error(m))}var c=d.length>1?Promise.all(d.map(function(m){return m(i)})):d[0](i);return new Promise(function(m,h){c.then(function(b){try{a._actionSubscribers.filter(function(_){return _.after}).forEach(function(_){return _.after(s,a.state)})}catch(_){process.env.NODE_ENV!=="production"&&(console.warn("[vuex] error in after action subscribers: "),console.error(_))}m(b)},function(b){try{a._actionSubscribers.filter(function(_){return _.error}).forEach(function(_){return _.error(s,a.state,b)})}catch(_){process.env.NODE_ENV!=="production"&&(console.warn("[vuex] error in error action subscribers: "),console.error(_))}h(b)})})},V.prototype.subscribe=function(r,o){return ie(r,this._subscribers,o)},V.prototype.subscribeAction=function(r,o){var a=typeof r=="function"?{before:r}:r;return ie(a,this._actionSubscribers,o)},V.prototype.watch=function(r,o,a){var l=this;return process.env.NODE_ENV!=="production"&&B(typeof r=="function","store.watch only accepts a function."),e.watch(function(){return r(l.state,l.getters)},o,Object.assign({},a))},V.prototype.replaceState=function(r){var o=this;this._withCommit(function(){o._state.data=r})},V.prototype.registerModule=function(r,o,a){a===void 0&&(a={}),typeof r=="string"&&(r=[r]),process.env.NODE_ENV!=="production"&&(B(Array.isArray(r),"module path must be a string or an Array."),B(r.length>0,"cannot register the root module by using registerModule.")),this._modules.register(r,o),F(this,this.state,r,this._modules.get(r),a.preserveState),H(this,this.state)},V.prototype.unregisterModule=function(r){var o=this;typeof r=="string"&&(r=[r]),process.env.NODE_ENV!=="production"&&B(Array.isArray(r),"module path must be a string or an Array."),this._modules.unregister(r),this._withCommit(function(){var a=Z(o.state,r.slice(0,-1));delete a[r[r.length-1]]}),de(this)},V.prototype.hasModule=function(r){return typeof r=="string"&&(r=[r]),process.env.NODE_ENV!=="production"&&B(Array.isArray(r),"module path must be a string or an Array."),this._modules.isRegistered(r)},V.prototype.hotUpdate=function(r){this._modules.update(r),de(this,!0)},V.prototype._withCommit=function(r){var o=this._committing;this._committing=!0,r(),this._committing=o},Object.defineProperties(V.prototype,W);var lt=Ee(function(t,r){var o={};return process.env.NODE_ENV!=="production"&&!Y(r)&&console.error("[vuex] mapState: mapper parameter must be either an Array or an Object"),we(r).forEach(function(a){var l=a.key,n=a.val;o[l]=function(){var s=this.$store.state,d=this.$store.getters;if(t){var c=Ne(this.$store,"mapState",t);if(!c)return;s=c.context.state,d=c.context.getters}return typeof n=="function"?n.call(this,s,d):s[n]},o[l].vuex=!0}),o}),st=Ee(function(t,r){var o={};return process.env.NODE_ENV!=="production"&&!Y(r)&&console.error("[vuex] mapMutations: mapper parameter must be either an Array or an Object"),we(r).forEach(function(a){var l=a.key,n=a.val;o[l]=function(){for(var s=[],d=arguments.length;d--;)s[d]=arguments[d];var c=this.$store.commit;if(t){var m=Ne(this.$store,"mapMutations",t);if(!m)return;c=m.context.commit}return typeof n=="function"?n.apply(this,[c].concat(s)):c.apply(this.$store,[n].concat(s))}}),o});function we(t){return Y(t)?Array.isArray(t)?t.map(function(r){return{key:r,val:r}}):Object.keys(t).map(function(r){return{key:r,val:t[r]}}):[]}function Y(t){return Array.isArray(t)||se(t)}function Ee(t){return function(r,o){return typeof r!="string"?(o=r,r=""):r.charAt(r.length-1)!=="/"&&(r+="/"),t(r,o)}}function Ne(t,r,o){var a=t._modulesNamespaceMap[o];return process.env.NODE_ENV!=="production"&&!a&&console.error("[vuex] module namespace not found in "+r+"(): "+o),a}const it={components:{DeleteConfirmationModal:G},props:{is_required:{type:Boolean,default:!1},error_message:{type:String,default:""},description:{type:String,default:""},show:{type:Boolean,default:!1},has_multiple_file:{show:Boolean,default:!1},field_name:{type:String,default:""},label_name:{type:String,default:""},route_url:{type:String,default:""},model_value:{type:Array,default:[]},file_config:{type:Object,default:{}},is_enable_delete:{type:Boolean,default:!0}},emits:["uploaded"],data(){return{media_id:"",error_message_data:"",open_delete_modal:!1,files:[],uploadFileList:[],isDragging:!1}},methods:{closeDeleteModal(){this.open_delete_modal=!1},deleteAction(){axios.delete(this.route_url+"/destroyMedia/"+this.media_id).then(t=>{let r=this.uploadFileList.findIndex(o=>o.id===this.media_id);r!==-1&&this.uploadFileList.splice(r,1),this.closeDeleteModal(),this.$store.commit("notification/SHOW_NOTIFICATION",{message:"Item deleted successfully.",type:"success",duration:5e3})}).catch(t=>{console.error(t),this.is_loading=!1})},getFileName(t){return t.length>12?t.substring(0,13)+"... ."+t.split(".")[1]:t},formatFileSize(t){if(t===0)return"0 Bytes";const r=1024,o=["Bytes","KB","MB","GB","TB"],a=Math.floor(Math.log(t)/Math.log(r));return parseFloat((t/Math.pow(r,a)).toFixed(2))+" "+o[a]},onDragOver(t){t.preventDefault(),this.isDragging=!0,t.dataTransfer.dropEffect="copy"},onDragLeave(t){t.preventDefault(),this.isDragging=!1},onDrop(t){t.preventDefault(),this.isDragging=!1;const r=t.dataTransfer.files;Array.from(r).forEach(o=>{this.uploadFile(o)})},async uploadFiles(t){const r=t.target.files,o=Array.from(r).map(a=>this.uploadFile(a));await Promise.all(o),this.$emit("uploaded")},getFirstError(t,r){return t.hasOwnProperty(r)?t[r][0]:""},async uploadFile(t){return new Promise((r,o)=>{t||r();const a=new FormData;a.append("file",t),Object.entries(this.file_config).forEach(([l,n])=>{a.append(l,n)}),this.files.push({file_name:t.name,loading:0}),axios.post(this.route_url+"/media",a,{onUploadProgress:l=>{this.files[this.files.length-1].loading=Math.floor(l.loaded/l.total*100)}}).then(l=>{let n=this.files.findIndex(i=>i.file_name===t.name);n!==-1&&this.files.splice(n,1),this.uploadFileList.push({file_name:l.data.file_name,size:l.data.size,id:l.data.id,url:l.data.url}),this.error_message_data="",r()}).catch(l=>{l.response.status===422?this.error_message_data=this.getFirstError(l.response.data.errors,"file"):console.error("An error occurred:",l);let n=this.files.findIndex(i=>i.file_name===t.name);n!==-1&&this.files.splice(n,1),console.log(l),r()})})}},computed:{uploadedFileIds(){var t;return this.has_multiple_file?this.uploadFileList.map(r=>r.id):((t=this.uploadFileList[0])==null?void 0:t.id)||null}},mounted(){console.log(this.model_value),this.model_value?Array.isArray(this.model_value)?this.uploadFileList=this.model_value:this.uploadFileList=[this.model_value]:this.uploadFileList=[],this.error_message_data=this.error_message}},dt={class:"flex flex-col items-center justify-center pt-5 pb-6"},ct=["multiple"],mt=["name"],gt=[e.createElementVNode("svg",{class:"w-8 h-8 mb-4 text-gray-500 dark:text-gray-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 16"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 13h3a3 3 0 0 0 0-6h-.025A5.56 5.56 0 0 0 16 6.5 5.5 5.5 0 0 0 5.207 5.021C5.137 5.017 5.071 5 5 5a4 4 0 0 0 0 8h2.167M10 15V6m0 0L8 8m2-2 2 2"})],-1),e.createElementVNode("p",{class:"text-sm text-gray-500 dark:text-gray-400"}," Drag & drop files or browse ",-1)],ft={key:1},ht=[e.createElementVNode("p",{class:"text-sm text-gray-500 dark:text-gray-400"},"Drop files here",-1)],ut={class:"mt-2 gl-span-form-error"},pt={class:"block mt-2 mb-3 text-sm font-normal leading-5 text-gray-500"},yt={key:0,class:""},bt={class:"flex items-center justify-between p-2 mb-2 text-gray-900 rounded-lg bg-gray-50 hover:bg-gray-100 hover:shadow dark:bg-gray-600 dark:hover:bg-gray-500 dark:text-white"},_t=e.createElementVNode("i",{class:"text-3xl fas fa-file-alt"},null,-1),kt={class:"w-full ml-3"},xt={class:"flex items-center justify-between mb-1"},wt={class:"text-xs text-black dark:text-white"},Et={class:"text-xs text-black dark:text-white"},Nt={class:"w-full h-1 mb-1 bg-white rounded-full dark:bg-gray-800"},Vt={class:"overflow-x-scroll max-h-56"},Bt={class:"flex items-center justify-between p-2 mb-2 text-gray-900 rounded-lg bg-gray-50 hover:bg-gray-100 hover:shadow dark:bg-gray-600 dark:hover:bg-gray-500 dark:text-white"},Ct={class:"flex items-center"},$t=e.createElementVNode("i",{class:"text-3xl fas fa-file-alt","aria-hidden":"true"},null,-1),St={class:"flex flex-col ml-3"},Dt={class:"text-xs"},Tt={class:"text-xs"},Ot={class:"flex gap-2"},Pt=["href"],jt=["onClick"];function At(t,r,o,a,l,n){const i=e.resolveComponent("DeleteConfirmationModal");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(i,{isOpen:l.open_delete_modal,onConfirmDelete:n.deleteAction,onCancelDelete:n.closeDeleteModal},null,8,["isOpen","onConfirmDelete","onCancelDelete"]),e.createElementVNode("div",{class:e.normalizeClass([{"border-red-500 dark:border-red-500":l.error_message_data!=="","border-gray-200 dark:border-gray-700":l.error_message_data==""},"w-full p-4 bg-white border rounded-lg shadow dark:bg-gray-800"])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":l.error_message_data=="","gl-label-form-invalid":l.error_message_data!=="",required:o.is_required})},e.toDisplayString(o.label_name),3),e.createElementVNode("div",{onDragover:r[3]||(r[3]=e.withModifiers((...s)=>n.onDragOver&&n.onDragOver(...s),["prevent"])),onDragleave:r[4]||(r[4]=e.withModifiers((...s)=>n.onDragLeave&&n.onDragLeave(...s),["prevent"])),onDrop:r[5]||(r[5]=e.withModifiers((...s)=>n.onDrop&&n.onDrop(...s),["prevent"])),class:"flex flex-col items-center justify-center w-full h-40 mt-3 mb-3 border-2 border-gray-300 border-dashed rounded-lg cursor-pointer bg-gray-50 dark:hover:bg-bray-800 dark:bg-gray-700 hover:bg-gray-100 dark:border-gray-600 dark:hover:border-gray-500 dark:hover:bg-gray-600"},[e.createElementVNode("div",dt,[e.createElementVNode("input",{type:"file",ref:"file_input"+o.field_name,hidden:"",multiple:o.has_multiple_file,onChange:r[0]||(r[0]=(...s)=>n.uploadFiles&&n.uploadFiles(...s))},null,40,ct),e.withDirectives(e.createElementVNode("input",{type:"hidden",name:o.field_name,"onUpdate:modelValue":r[1]||(r[1]=s=>n.uploadedFileIds=s)},null,8,mt),[[e.vModelText,n.uploadedFileIds]]),l.isDragging?(e.openBlock(),e.createElementBlock("div",ft,ht)):(e.openBlock(),e.createElementBlock("div",{key:0,class:"flex flex-col items-center justify-center",onClick:r[2]||(r[2]=s=>t.$refs["file_input"+this.field_name].click())},gt))])],32),e.createElementVNode("span",ut,e.toDisplayString(l.error_message_data),1),e.createElementVNode("small",pt,e.toDisplayString(o.description),1),l.files.length>0?(e.openBlock(),e.createElementBlock("section",yt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.files,(s,d)=>(e.openBlock(),e.createElementBlock("li",bt,[_t,e.createElementVNode("div",kt,[e.createElementVNode("div",xt,[e.createElementVNode("span",wt,e.toDisplayString(n.getFileName(s.file_name)),1),e.createElementVNode("span",Et,e.toDisplayString(s.loading),1)]),e.createElementVNode("div",Nt,[e.createElementVNode("div",{class:"h-full bg-gray-500 rounded-full dark:bg-gray-400",style:e.normalizeStyle({width:s.loading+"%"})},null,4)])])]))),256))])):e.createCommentVNode("",!0),e.createElementVNode("section",Vt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.uploadFileList,(s,d)=>(e.openBlock(),e.createElementBlock("li",Bt,[e.createElementVNode("div",Ct,[$t,e.createElementVNode("div",St,[e.createElementVNode("span",Dt,e.toDisplayString(n.getFileName(s.file_name)),1),e.createElementVNode("span",Tt,e.toDisplayString(n.formatFileSize(s.size)),1)])]),e.createElementVNode("div",Ot,[e.createElementVNode("a",{href:s.url,target:"_blank",class:"text-lg text-blue-600 cursor-pointer dark:text-blue-400 fas fa-download"},null,8,Pt),o.is_enable_delete?(e.openBlock(),e.createElementBlock("i",{key:0,onClick:c=>{l.media_id=s.id,l.open_delete_modal=!0},class:"text-lg text-red-600 cursor-pointer dark:text-red-400 fas fa-x"},null,8,jt)):e.createCommentVNode("",!0)])]))),256))])],2)],64)}const Mt=k(it,[["render",At]]),Lt={computed:{...lt("notification",["notification"]),alertClasses(){switch(this.notification.type){case"info":return"text-blue-800 bg-blue-50 dark:bg-gray-800 dark:text-blue-400";case"error":return"text-red-800 bg-red-50 dark:bg-gray-800 dark:text-red-400";case"success":return"text-green-800 bg-green-50 dark:bg-gray-800 dark:text-green-400";case"warning":return"text-yellow-800 bg-yellow-50 dark:bg-gray-800 dark:text-yellow-300";case"dark":return"text-gray-800 bg-gray-50 dark:bg-gray-800 dark:text-gray-300";default:return""}},buttonClasses(){switch(this.notification.type){case"info":return"bg-blue-50 text-blue-500 focus:ring-blue-400 hover:bg-blue-200 dark:hover:bg-gray-700";case"error":return"bg-red-50 text-red-500 focus:ring-red-400 hover:bg-red-200 dark:hover:bg-gray-700";case"success":return"bg-green-50 text-green-500 focus:ring-green-400 hover:bg-green-200 dark:hover:bg-gray-700";case"warning":return"bg-yellow-50 text-yellow-500 focus:ring-yellow-400 hover:bg-yellow-200 dark:hover:bg-gray-700";case"dark":return"bg-gray-50 text-gray-500 focus:ring-gray-400 hover:bg-gray-200 dark:hover:bg-gray-700";default:return""}}},methods:{...st("notification",["HIDE_NOTIFICATION"]),dismiss(){this.HIDE_NOTIFICATION()}},watch:{"notification.show":function(t){t&&setTimeout(()=>{this.dismiss()},this.notification.duration)}}},It=e.createElementVNode("svg",{class:"flex-shrink-0 w-4 h-4","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5ZM9.5 4a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3ZM12 15H8a1 1 0 0 1 0-2h1v-3H8a1 1 0 0 1 0-2h2a1 1 0 0 1 1 1v4h1a1 1 0 0 1 0 2Z"})],-1),zt=e.createElementVNode("span",{class:"sr-only"},"Info",-1),Gt={class:"mr-3 text-sm font-medium ms-3"},Ft=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{class:"w-3 h-3","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 14 14"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m1 1 6 6m0 0 6 6M7 7l6-6M7 7l-6 6"})],-1)];function Ut(t,r,o,a,l,n){return t.notification.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["fixed right-0 z-50 flex items-center p-4 m-5 mb-4 rounded-lg shadow-lg",n.alertClasses]),role:"alert"},[It,zt,e.createElementVNode("div",Gt,e.toDisplayString(t.notification.message),1),e.createElementVNode("button",{type:"button",onClick:r[0]||(r[0]=(...i)=>n.dismiss&&n.dismiss(...i)),class:e.normalizeClass(["inline-flex items-center justify-center w-6 h-6 p-1 -mx-1 -my-1 rounded-lg ms-auto focus:ring-2 hover:bg-opacity-50",n.buttonClasses]),"aria-label":"Close"},Ft,2)],2)):e.createCommentVNode("",!0)}const Rt=k(Lt,[["render",Ut]]),qt={components:{},props:{field_name:{type:String,default:""},trans_selector_name:{type:String,default:"i18n_selector"}},data(){return{locals:[],default_language:""}},methods:{getLocals(){const t={id:this.menu_id};axios.get("/admin/get_locals",{params:t}).then(r=>{this.locals=r.data.locals,this.default_language=r.data.default_language,console.log("default_language",this.default_language)}).catch(r=>{console.error(r)})}},created(){this.getLocals()},mounted(){}},Ht={class:"grid w-full gap-1 mt-5 mb-5 md:gap-0 md:grid-cols-10 language-selector"},Zt=["name","value","id","checked"],Kt=["for"];function vt(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("ul",Ht,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.locals,(i,s)=>(e.openBlock(),e.createElementBlock("li",null,[e.createElementVNode("input",{type:"radio",name:o.trans_selector_name,value:i,class:"hidden peer",id:i+"_"+o.field_name,autocomplete:"off",checked:i===l.default_language},null,8,Zt),e.createElementVNode("label",{for:i+"_"+o.field_name,class:e.normalizeClass([{"border md:!rounded-s-lg":s===0,"border md:!rounded-e-lg":s===l.locals.length-1,"border-t border-b":s!==0&&s!==l.locals.length-1},"w-full p-1 font-bold text-center text-gray-500 uppercase bg-white border-gray-200 rounded-lg cursor-pointer md:rounded-none dark:hover:text-gray-300 dark:border-gray-700 dark:peer-checked:text-blue-500 peer-checked:border-blue-600 peer-checked:text-blue-600 hover:text-gray-600 hover:bg-gray-100 dark:text-gray-400 dark:bg-gray-800 dark:hover:bg-gray-700"])},e.toDisplayString(i),11,Kt)]))),256))])}const Wt=k(qt,[["render",vt]]),Yt={class:"bg-white border rounded-lg border-stroke shadow-default dark:border-strokedark dark:bg-boxdark"},Xt={class:"px-3 py-4 border-b border-stroke dark:border-strokedark"},Jt={class:"font-semibold text-black dark:text-white"},Qt={key:0,class:"p-6"},er={__name:"GlCard",props:{class:{type:String,default:""}},setup(t){const r=t,o=e.computed(()=>r.class);return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["flex flex-col gap-9",o.value])},[e.createElementVNode("div",Yt,[e.createElementVNode("div",Xt,[e.createElementVNode("h3",Jt,[e.renderSlot(a.$slots,"header")])]),a.$slots.body?(e.openBlock(),e.createElementBlock("div",Qt,[e.renderSlot(a.$slots,"body")])):e.createCommentVNode("",!0)])],2))}},tr={class:"font-bold ptext-lg dark:text-white"},rr={class:"mt-3 mb-4"},or={class:"bg-blue-100 text-blue-800 text-sm font-medium mb-2 mt-2 me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},nr=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),ar=["name","value"],lr={key:0,class:"dropdown"},sr={class:"border border-gray-200 rounded-lg focus:ring-blue-500 focus:border-blue-500 dark:border-gray-600 dark:focus:ring-blue-500 dark:focus:border-blue-500"},ir={class:"relative"},dr=["onClick"],cr={class:"text-gray-700 bg-white dark:border-strokedark dark:bg-boxdark dark:text-gray-200 !border-b !border-t-0 !border-r !border-l absolute w-full z-[999999999] showOptions"},mr={class:"p-1"},gr=e.createElementVNode("label",{for:"default-search",class:"mb-2 text-sm font-medium text-gray-900 sr-only dark:text-white"},"Search",-1),fr={class:"relative"},hr=e.createElementVNode("div",{class:"absolute inset-y-0 flex items-center pointer-events-none start-0 ps-3"},[e.createElementVNode("svg",{class:"w-4 h-4 text-gray-500 dark:text-gray-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m19 19-4-4m0-7A7 7 0 1 1 1 8a7 7 0 0 1 14 0Z"})])],-1),ur=["id"],pr={class:"overflow-y-auto max-h-64"},yr=["onClick","onMousedown","id"],br={__name:"GlMultiSelectDropdown",props:{modelValue:{type:[String,Number],default:""},defaultValue:{type:[String,Number],default:""},field_name:{type:String,default:""},is_required:{type:Boolean,default:!1},has_cancel:{type:Boolean,default:!0},label_name:{type:String,default:""},options:{type:Array,required:!0,default:()=>[],note:"Options of dropdown. An array of options with id and name"},placeholder:{type:String,required:!1,default:"Please select an option",note:"Placeholder of dropdown"},maxItem:{type:Number,required:!1,default:1e4,note:"Max items showing"},show:{type:Boolean,default:!1},error_message:{type:String,default:""},description:{type:String,default:""}},emits:["update:modelValue","selected","selectionChanged"],setup(t,{emit:r}){const o=t,a=r,l=e.ref(null),n=e.ref([]),i=e.ref([]),s=e.ref(0),d=e.ref(!1),c=e.ref(""),m=e.ref("");e.onMounted(()=>{m.value=j(),o.show||(document.body.addEventListener("click",g=>{re(g)}),document.addEventListener("keypress",g=>{g.key==="Enter"&&g.target.form&&g.preventDefault()}))});const h=e.computed(()=>z()),b=e.computed(()=>f()),_=e.computed(()=>{const g=[],u=new RegExp(c.value,"ig");for(const y of h.value){const w=String(y.name);(c.value.length<1||w.match(u))&&g.length<o.maxItem&&g.push(y)}return g});function S(g){if(["ArrowLeft","ArrowUp","ArrowRight","ArrowDown","Enter"].includes(g.key)){if(["ArrowUp","ArrowDown"].includes(g.key)&&g.preventDefault(),g.key==="ArrowDown"&&o.posts==="")return;oe(g.key)}}function j(){let g=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(y){const w=(g+Math.random()*16)%16|0;return g=Math.floor(g/16),(y==="x"?w:w&3|8).toString(16)})}function A(g){return g!=[]&&g.every(u=>typeof u=="object"&&u!==null)}function M(g){return g.every(u=>typeof u=="object"&&u!==null)}function Q(g){return n.value.findIndex(u=>u.id===g)!==-1}function ee(){n.value=z()}function te(){n.value=[]}function re(g){g.target.id!=o.field_name+"search"+m.value&&g.target.id!=o.field_name&&!g.target.classList.contains("showOptions")&&($(),s.value=0)}function L(g){const u=`${g}${m.value}`,y=document.getElementById(u);y&&y.scrollIntoView()}function I(g){const u=`${g}${m.value}`,y=document.getElementById(u);y&&y.click()}function oe(g){g==="ArrowDown"&&s.value<_.value.length&&(s.value++,L(s.value)),g==="ArrowUp"&&s.value>1&&(s.value--,L(s.value)),g==="Enter"&&I(s.value)}function z(){return o.options.map((g,u)=>typeof g=="object"?g:{id:g,name:g})}function f(){if(console.log("selected.value",n.value),console.log("props.modelValue",o.modelValue),console.log("isArrayObjectNotEmpty",A(n.value)),A(n.value))return M(n.value)?h.value.filter(g=>n.value.some(u=>String(u.id)===String(g.id)))||[]:h.value.filter(g=>n.value.some(u=>String(u)===String(g.id)))||[];if(o.modelValue)return M(o.modelValue)?h.value.filter(g=>o.modelValue.some(u=>String(u.id)===String(g.id)))||[]:h.value.filter(g=>o.modelValue.some(u=>String(u)===String(g.id)))||[]}function x(g){let u=n.value.findIndex(y=>y.id===g.id);u!==-1?n.value.splice(u,1):n.value.push(g),d.value=!1,i.value=n.value.map(y=>y.id),a("update:modelValue",i.value),a("selected",i.value),a("selectionChanged",i.value)}function E(){o.show||(c.value="",d.value=!0,e.nextTick(()=>{var g=document.getElementById(`${o.field_name}search${m.value}`);g&&g.focus()}))}function $(){n.value.id||(n.value=[],c.value=""),a("selected",n.value),d.value=!1}return e.watch(c,()=>{_.value.length===0&&(n.value=[])}),e.watch(n,g=>{A(n.value)&&(i.value=n.value.map(u=>u.id),a("update:modelValue",i.value))}),(g,u)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",tr,e.toDisplayString(t.label_name),1),e.createElementVNode("p",rr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(y,w)=>(e.openBlock(),e.createElementBlock("span",or,e.toDisplayString(y==null?void 0:y.name),1))),256))]),nr],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(y,w)=>(e.openBlock(),e.createElementBlock("input",{type:"hidden",name:t.field_name+"[]",key:w,value:y},null,8,ar))),128)),t.options?(e.openBlock(),e.createElementBlock("div",lr,[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required})},e.toDisplayString(t.label_name),3),e.createElementVNode("div",{class:"inline-flex ml-2 rounded-md shadow-sm",role:"group"},[e.createElementVNode("button",{onClick:ee,type:"button",class:"px-4 py-0 text-sm font-medium text-gray-900 bg-transparent border border-gray-900 rounded-s-md hover:bg-gray-900 hover:text-white focus:z-10 focus:bg-gray-900 focus:text-white dark:border-white dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:bg-gray-700"}," Select all "),e.createElementVNode("button",{onClick:te,type:"button",class:"px-4 py-0 text-sm font-medium text-gray-900 bg-transparent border border-gray-900 rounded-e-md hover:bg-gray-900 hover:text-white focus:z-10 focus:bg-gray-900 focus:text-white dark:border-white dark:text-white dark:hover:text-white dark:hover:bg-gray-700 dark:focus:bg-gray-700"}," Deselect all ")]),e.createElementVNode("div",sr,[e.createElementVNode("div",ir,[e.createElementVNode("div",{class:"flex flex-wrap gap-2 pl-8 pr-2 gl-multi-dropdown showOptions",onClick:u[0]||(u[0]=y=>E())},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(y,w)=>(e.openBlock(),e.createElementBlock("span",{key:w,class:"px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded pointer-events-none dark:bg-blue-900 dark:text-blue-300"},[e.createTextVNode(e.toDisplayString(y==null?void 0:y.name)+" ",1),e.createElementVNode("i",{onClick:e.withModifiers(R=>g.clearOption(y),["stop"]),class:"cursor-pointer pointer-events-auto hover:text-red-600 dark:hover:text-red-400 fas fa-times"},null,8,dr)]))),128))]),e.createElementVNode("i",{class:e.normalizeClass([d.value?"fa-angle-up":"fa-angle-down","absolute text-xl text-gray-500 cursor-pointer fas right-2 hover:text-gray-700"]),style:{top:"11px"}},null,2)]),e.withDirectives(e.createElementVNode("div",cr,[e.createElementVNode("div",mr,[gr,e.createElementVNode("div",fr,[hr,e.withDirectives(e.createElementVNode("input",{type:"search","onUpdate:modelValue":u[1]||(u[1]=y=>c.value=y),ref:l.value,id:`${t.field_name}search${m.value}`,onKeydown:S,onBlur:u[2]||(u[2]=y=>$()),autocomplete:"off",class:"block w-full p-2 text-sm text-gray-900 border border-gray-300 rounded-lg ps-10 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500",placeholder:"Search ..."},null,40,ur),[[e.vModelText,c.value]])])]),e.createElementVNode("div",pr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(_.value,(y,w)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["block px-2 py-2 text-xs leading-4 text-gray-700 no-underline cursor-pointer dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white",w+1==s.value||Q(y.id)?"bg-gray-100 dark:bg-gray-600":""]),onClick:R=>x(y),onMousedown:R=>x(y),key:w,id:w+1},e.toDisplayString(y.name||y.id||"-"),43,yr))),128))])],512),[[e.vShow,d.value]])])])):e.createCommentVNode("",!0)],2))],64))}},_r={props:{button_type:{type:String,default:"default"},is_submit:{type:Boolean,default:!1},icon:{type:String,default:""},is_loading:{type:Boolean,default:!1},is_disabled:{type:Boolean,default:!1},tag:{type:String,default:"button"},href:{type:String,default:""}},computed:{buttonTypeClass(){switch(this.button_type){case"default":return"text-white bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800";case"alternative":return" text-gray-900 bg-white border border-gray-200 hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:ring-4 focus:ring-gray-100 dark:focus:ring-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:text-white dark:hover:bg-gray-700";case"dark":return"text-white bg-gray-800 hover:bg-gray-900 focus:ring-4 focus:ring-gray-300 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-700 dark:border-gray-700";case"light":return"text-gray-900 bg-white border border-gray-300 hover:bg-gray-100 focus:ring-4 focus:ring-gray-100 dark:bg-gray-800 dark:text-white dark:border-gray-600 dark:hover:bg-gray-700 dark:hover:border-gray-600 dark:focus:ring-gray-700";case"green":return" text-white bg-green-700 hover:bg-green-800 focus:ring-4 focus:ring-green-300 dark:bg-green-600 dark:hover:bg-green-700 dark:focus:ring-green-800";case"red":return" text-white bg-red-700 hover:bg-red-800 focus:ring-4 focus:ring-red-300 dark:bg-red-600 dark:hover:bg-red-700 dark:focus:ring-red-900";case"yellow":return" text-white bg-yellow-400 hover:bg-yellow-500 focus:ring-4 focus:ring-yellow-300 dark:focus:ring-yellow-900";case"purple":return" text-white bg-purple-700 hover:bg-purple-800 focus:ring-4 focus:ring-purple-300 dark:bg-purple-600 dark:hover:bg-purple-700 dark:focus:ring-purple-900";default:return""}}},methods:{}},kr=e.createElementVNode("svg",{"aria-hidden":"true",role:"status",class:"inline w-4 h-4 me-3 animate-spin",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),e.createElementVNode("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"#1C64F2"})],-1);function xr(t,r,o,a,l,n){return o.is_loading?(e.openBlock(),e.createBlock(e.resolveDynamicComponent("button"),{key:1,disabled:"",class:e.normalizeClass(`flex items-center gap-2 focus:outline-none text-sm px-2 py-2 me-2 font-medium rounded-lg ${n.buttonTypeClass}`)},{default:e.withCtx(()=>[kr,e.createTextVNode(" Loading... ")]),_:1},8,["class"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.tag),e.mergeProps({key:0,type:o.is_submit,disabled:o.is_disabled},{type:o.is_submit?"submit":void 0},{href:o.tag==="a"?o.href:void 0,class:` ${o.is_disabled?"cursor-not-allowed opacity-50":""} flex items-center gap-2 focus:outline-none text-sm px-5 py-2 me-2 font-medium rounded-lg ${n.buttonTypeClass}`}),{default:e.withCtx(()=>[o.icon?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass([o.icon,"text-base"])},null,2)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default")]),_:3},16,["type","disabled","href","class"]))}const wr=k(_r,[["render",xr]]),Er={class:"font-bold ptext-lg dark:text-white"},Nr=["name","id"],Vr=["id"],Br=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Cr=["for"],$r=e.createElementVNode("span",{class:"language-label js-language-label bg-blue-100 text-blue-800 text-xs font-medium me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},null,-1),Sr=["name","id"],Dr=["required","name","id","type"],Tr={class:"gl-span-form-error"},Or={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},Pr={__name:"GlTextareaTranslate",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:null},modelValue:{type:[String,Number],default:""},model_value_translate:{type:[String,Object],default:null},modelValueTranslate:{type:[String,Object],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},get_field_translations:{type:String,default:""},description:{type:String,default:""},translatable:{type:Object,default:null}},emits:["update:modelValue","update:modelValueTranslate","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null),i=e.ref(null);return e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus(),a.model_value&&(l("update:modelValue",a.model_value),n.value.value=a.model_value),a.model_value_translate,a.translatable&&axios.post("/admin/get_field_translations",{model:a.translatable.model,row_id:a.translatable.row_id,field:a.translatable.field}).then(s=>{i.value.value=JSON.stringify(s.data),l("update:modelValueTranslate",JSON.stringify(s.data)),console.log("input_translate",i.value.value)}).catch(s=>{console.log(s)})}),r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",Er,e.toDisplayString(t.label_name),1),e.withDirectives(e.createElementVNode("input",{type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",ref_key:"input_translate",ref:i,"onUpdate:modelValue":d[0]||(d[0]=c=>s.inputTranslateValue=c)},null,8,Nr),[[e.vModelText,s.inputTranslateValue]]),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,Vr),Br],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-translation-form":t.error_message=="","gl-label-translation-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,Cr),$r,e.createElementVNode("input",{class:"mb-4",type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",onInput:d[1]||(d[1]=c=>s.$emit("update:modelValueTranslate",c.target.value)),ref_key:"input_translate",ref:i},null,40,Sr),e.createElementVNode("textarea",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({" gl-textarea-form form-input-translation mt-4 ":t.error_message==""," gl-textarea-form-invalid form-input-translation mt-4 ":t.error_message!==""}),type:t.type,onInput:d[2]||(d[2]=c=>s.$emit("update:modelValue",c.target.value)),onKeydown:d[3]||(d[3]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,rows:"4"},`
6
6
  `,42,Dr),e.createElementVNode("span",Tr,e.toDisplayString(t.error_message),1),e.createElementVNode("small",Or,e.toDisplayString(t.description),1)],2))],64))}},jr={class:"font-bold ptext-lg dark:text-white"},Ar=["name","id"],Mr=["id"],Lr=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Ir=["for"],zr=e.createElementVNode("span",{class:"language-label js-language-label bg-blue-100 text-blue-800 text-xs font-medium me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},null,-1),Gr=["name","id"],Fr=["name","id","type"],Ur={class:"gl-span-form-error"},Rr={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},qr={__name:"GlTinymceTranslate",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:null},modelValue:{type:[String,Number],default:""},model_value_translate:{type:[String,Object],default:null},modelValueTranslate:{type:[String,Object],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},get_field_translations:{type:String,default:""},description:{type:String,default:""},translatable:{type:Object,default:null}},emits:["update:modelValue","update:modelValueTranslate","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null),i=e.ref(null);return e.onMounted(()=>{tinymce.init({selector:"#"+a.field_name,width:"100%",height:300}),console.log("tinymce ",a.model_value),n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus(),a.model_value&&(l("update:modelValue",a.model_value),n.value.value=a.model_value),a.model_value_translate,a.translatable&&axios.post("/admin/get_field_translations",{model:a.translatable.model,row_id:a.translatable.row_id,field:a.translatable.field}).then(s=>{i.value.value=JSON.stringify(s.data),l("update:modelValueTranslate",JSON.stringify(s.data))}).catch(s=>{console.log(s)})}),r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",jr,e.toDisplayString(t.label_name),1),e.withDirectives(e.createElementVNode("input",{type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",ref_key:"input_translate",ref:i,"onUpdate:modelValue":d[0]||(d[0]=c=>s.inputTranslateValue=c)},null,8,Ar),[[e.vModelText,s.inputTranslateValue]]),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,Mr),Lr],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-translation-form":t.error_message=="","gl-label-translation-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,Ir),zr,e.createElementVNode("input",{class:"mb-4",type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",onInput:d[1]||(d[1]=c=>s.$emit("update:modelValueTranslate",c.target.value)),ref_key:"input_translate",ref:i},null,40,Gr),e.createElementVNode("textarea",{name:t.field_name,id:t.field_name,class:e.normalizeClass(["tiny",{" gl-textarea-form form-input-translation mt-4 ":t.error_message==""," gl-textarea-form-invalid form-input-translation mt-4 ":t.error_message!==""}]),type:t.type,onInput:d[2]||(d[2]=c=>s.$emit("update:modelValue",c.target.value)),onKeydown:d[3]||(d[3]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,rows:"4"},`
7
- `,42,Fr),e.createElementVNode("span",Ur,e.toDisplayString(t.error_message),1),e.createElementVNode("small",Rr,e.toDisplayString(t.description),1)],2))],64))}},Hr={class:"font-bold ptext-lg dark:text-white"},Zr=["name","id"],Kr=["id"],vr=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Wr=["for"],Yr=e.createElementVNode("span",{class:"language-label js-language-label bg-blue-100 text-blue-800 text-xs font-medium me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},null,-1),Xr=["name","id"],Jr=["required","name","id","type"],Qr={class:"gl-span-form-error"},eo={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},to={__name:"GlTextTranslate",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:null},modelValue:{type:[String,Number],default:""},model_value_translate:{type:[String,Object],default:null},modelValueTranslate:{type:[String,Object],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},get_field_translations:{type:String,default:""},description:{type:String,default:""},translatable:{type:Object,default:null}},emits:["update:modelValue","update:modelValueTranslate","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null),i=e.ref(null);return e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus(),a.model_value&&(l("update:modelValue",a.model_value),n.value.value=a.model_value),a.model_value_translate,a.translatable&&axios.post("/admin/get_field_translations",{model:a.translatable.model,row_id:a.translatable.row_id,field:a.translatable.field}).then(s=>{i.value.value=JSON.stringify(s.data),l("update:modelValueTranslate",JSON.stringify(s.data))}).catch(s=>{console.log(s)})}),r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",Hr,e.toDisplayString(t.label_name),1),e.withDirectives(e.createElementVNode("input",{type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",ref:"input_translate_s","onUpdate:modelValue":d[0]||(d[0]=c=>s.inputTranslateValue=c)},null,8,Zr),[[e.vModelText,s.inputTranslateValue]]),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,Kr),vr],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-translation-form":t.error_message=="","gl-label-translation-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,Wr),Yr,e.createElementVNode("input",{class:"mb-4",type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",onInput:d[1]||(d[1]=c=>s.$emit("update:modelValueTranslate",c.target.value)),ref_key:"input_translate",ref:i},null,40,Xr),e.createElementVNode("input",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({" gl-input-form form-input-translation mt-2 ":t.error_message==""," gl-input-form-invalid form-input-translation mt-2 ":t.error_message!==""}),type:t.type,onInput:d[2]||(d[2]=c=>s.$emit("update:modelValue",c.target.value)),onKeydown:d[3]||(d[3]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n},null,42,Jr),e.createElementVNode("span",Qr,e.toDisplayString(t.error_message),1),e.createElementVNode("small",eo,e.toDisplayString(t.description),1)],2))],64))}},ro={class:"font-bold ptext-lg dark:text-white"},oo={class:"mb-4 text-base text-gray-900 dark:text-white"},no=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),ao=["for"],lo=["required","name","id","type","placeholder"],so={class:"gl-span-form-error"},io={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},co={__name:"GlTextInput",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:""},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},description:{type:String,default:""},placeholder:{type:String,default:""}},emits:["update:modelValue","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null);e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus()});const i=e.computed({get(){return a.modelValue},set(s){l("update:modelValue",s)}});return r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",ro,e.toDisplayString(t.label_name),1),e.createElementVNode("p",oo,e.toDisplayString(t.type=="password"?t.modelValue.replace(/./g,"*"):t.modelValue),1),no],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,ao),e.withDirectives(e.createElementVNode("input",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({"gl-input-form":t.error_message=="","gl-input-form-invalid":t.error_message!==""}),type:t.type,"onUpdate:modelValue":d[0]||(d[0]=c=>i.value=c),onKeydown:d[1]||(d[1]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,placeholder:t.placeholder},null,42,lo),[[e.vModelDynamic,i.value]]),e.createElementVNode("span",so,e.toDisplayString(t.error_message),1),e.createElementVNode("small",io,e.toDisplayString(t.description),1)],2))],64))}},mo={setup(t,{slots:r}){const o=e.ref(r.default().map(l=>l.props)),a=e.ref(o.value[0].title);return e.provide("selectedTitle",a),{tabs:o,selectedTitle:a}}},go={class:"flex flex-wrap"},fo={class:"w-full"},ho={class:"flex flex-row flex-wrap gap-1 pt-3 pb-4 mb-0 list-none"},uo=["onClick"],po={class:"relative flex flex-col w-full min-w-0 mb-6 break-words bg-white rounded shadow-lg dark:border-strokedark dark:bg-boxdark"},yo={class:"flex-auto px-4 py-5"},bo={class:"tab-content tab-space"};function _o(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",go,[e.createElementVNode("div",fo,[e.createElementVNode("ul",ho,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.tabs,i=>(e.openBlock(),e.createElementBlock("li",{key:i.title,onClick:s=>a.selectedTitle=i.title,class:"flex-auto -mb-px text-center"},[e.createElementVNode("a",{class:e.normalizeClass([{"text-slate-600 bg-white dark:bg-meta-4":a.selectedTitle!=i.title,"text-white bg-slate-600 dark:bg-primary":a.selectedTitle===i.title},"block px-5 py-3 text-xs font-bold leading-normal rounded shadow-lg hover:text-white tex hover:bg-slate-600 dark:hover:bg-primary dark:text-white tabs_buttons"])},[e.createElementVNode("i",{class:e.normalizeClass([i.icon,"mr-1 text-base"])},null,2),e.createTextVNode(" "+e.toDisplayString(i.title),1)],2)],8,uo))),128))])])]),e.createElementVNode("div",po,[e.createElementVNode("div",yo,[e.createElementVNode("div",bo,[e.renderSlot(t.$slots,"default")])])])],64)}const ko=k(mo,[["render",_o]]),xo={props:["title"],setup(){return{selectedTitle:e.inject("selectedTitle")}}},wo={key:0,class:"block"};function Eo(t,r,o,a,l,n){return o.title==a.selectedTitle?(e.openBlock(),e.createElementBlock("div",wo,[e.renderSlot(t.$slots,"default")])):e.createCommentVNode("",!0)}const No=k(xo,[["render",Eo]]),Vo={props:{elements_to_show_prop:{type:Number,default:3},hide_arrow:{type:Boolean,default:!1},disable_touch:{type:Boolean,default:!1},direction_property:{type:String,default:"ltr"},slider_arrows_indicators_position:{type:String,default:"arrows_outside_slider"}},data:function(){return{elementsToShow:3,dotsNum:0,currentDot:1,dotsNavigation:[],touchStartX:0,isMoving:!1,initialX:0,initialY:0,Random_string:this.generateRandomString(6)}},mounted(){this.elementsToShow=this.elements_to_show_prop,this.initSlider(),this.disable_touch||this.movingActions()},methods:{sliderIndicatorsAction(){var t="";return this.direction_property=="rtl"?(t+=" space-x-reverse ",t+=" slider_indicators "):this.slider_arrows_indicators_position=="arrows_indicators_inside_slider"&&(t+=" slider_indicators "),t},sliderContainerAction(){var t="";return!this.hide_arrow&&this.slider_arrows_indicators_position=="arrows_outside_slider"?t+=" w-12/12 xl:w-8/12 xxl:w-8/12 md:w-8/12 sm:w-8/12":this.slider_arrows_indicators_position!="arrows_outside_slider"&&(t+=" w-12/12 "),t},generateRandomString(t){let r="";const o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",a=o.length;for(let l=0;l<t;l++)r+=o.charAt(Math.floor(Math.random()*a));return r},movingActions(){let t=this,r=document.getElementById("slider_"+this.Random_string);const o=l=>{r.style.cursor="grabbing";const n=s=>{const d=s.clientX||s.touches&&s.touches[0]&&s.touches[0].clientX,c=s.clientY||s.touches&&s.touches[0]&&s.touches[0].clientY,m=d-t.initialX,h=c-t.initialY;Math.abs(m)>Math.abs(h)?(s.preventDefault(),Math.abs(m)>=70&&(m<0?t.next():t.prev(),t.initialX=d)):r.style.cursor="grab",Math.abs(h)>Math.abs(m)&&(r.style.cursor="grab")},i=()=>{document.removeEventListener("mousemove",n),document.removeEventListener("touchmove",n),document.removeEventListener("mouseup",i),document.removeEventListener("touchend",i),r.style.cursor="grab"};document.addEventListener("mousemove",n),document.addEventListener("touchmove",n,{passive:!1}),document.addEventListener("mouseup",i),document.addEventListener("touchend",i),t.initialX=l.clientX||l.touches&&l.touches[0]&&l.touches[0].clientX,t.initialY=l.clientY||l.touches&&l.touches[0]&&l.touches[0].clientY},a=l=>{l.key==="ArrowLeft"?t.prev():l.key==="ArrowRight"&&t.next()};r.addEventListener("mousedown",o),r.addEventListener("touchstart",o),document.addEventListener("keydown",a)},next(){this.currentDot<this.dotsNavigation.length&&(this.currentDot++,this.setDot(this.currentDot))},prev(){this.currentDot>1&&(this.currentDot--,this.setDot(this.currentDot))},initSlider(){let t=document.getElementById("sliderContainer_"+this.Random_string),r=document.getElementById("mainSliderContainer_"+this.Random_string),o=document.getElementById("slider_"+this.Random_string),a=o.querySelectorAll("li"),l=Array.from(a).filter(s=>s.parentNode===o),n=t.clientWidth,i=n/this.elementsToShow;if(this.elementsToShow>1?document.body.clientWidth<1e3?(this.elementsToShow=1,i=this.hide_arrow?r.clientWidth:n):document.body.clientWidth<1500&&(this.elementsToShow=2):(this.elementsToShow=1,i=this.hide_arrow?r.clientWidth:n),l.length>1){this.dotsNum=this.elementsToShow==1?l.length:l.length-this.elementsToShow+1;let s=this.elementsToShow==1?i*l.length/this.dotsNum:i*(l.length-this.elementsToShow)/(this.dotsNum-1);this.dotsNavigation=[];for(let d=0;d<this.dotsNum;d++)this.dotsNavigation.push(s*d)}o.style.width=l.length*i+"px",o.style.transition="margin",o.style.transitionDuration="1s";for(let s=0;s<l.length;s++){const d=l[s];d.style.width=i+"px"}},setDot(t){let r=document.getElementById("slider_"+this.Random_string);this.direction_property=="rtl"?r.style.marginRight=-this.dotsNavigation[t-1]+"px":r.style.marginLeft=-this.dotsNavigation[t-1]+"px",this.currentDot=t}}},N=t=>(e.pushScopeId("data-v-a94f16a9"),t=t(),e.popScopeId(),t),Bo=["id"],Co={key:0,class:"items-center hidden w-2/12 xl:flex xxl:flex md:flex sm:flex arrow_button"},$o={class:"w-full"},So={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Do=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],To={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Oo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],Po=["id"],jo=["id"],Ao={class:"w-full"},Mo={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Lo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],Io={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},zo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],Go={class:"w-full"},Fo={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Uo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],Ro={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},qo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],Ho=["onClick"],Zo=[N(()=>e.createElementVNode("span",null,null,-1))],Ko={key:1,class:"flex justify-between pl-5 pr-5"},vo=["onClick"],Wo=[N(()=>e.createElementVNode("span",null,null,-1))],Yo={key:0,class:"flex"},Xo={class:"flex items-center"},Jo={class:"w-full"},Qo={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},en=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],tn={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},rn=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],on={class:"flex items-center"},nn={class:"w-full"},an={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},ln=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],sn={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},dn=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],cn={key:1,class:"items-center hidden w-2/12 xl:flex xxl:flex md:flex sm:flex arrow_button"},mn={class:"w-full"},gn={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},fn=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],hn={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},un=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))];function pn(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",{class:e.normalizeClass(["",!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_outside_slide"?"flex":"relative block"]),id:"mainSliderContainer_"+t.Random_string},[t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_outside_slider"?(e.openBlock(),e.createElementBlock("div",Co,[e.createElementVNode("div",$o,[e.createElementVNode("button",{class:"p-3 mr-5 rounded-full shadow-lg arrow_button_styles",onClick:r[0]||(r[0]=i=>n.prev())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",So,Do)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",To,Oo)):e.createCommentVNode("",!0)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["overflow-hidden",n.sliderContainerAction()]),id:"sliderContainer_"+t.Random_string},[e.createElementVNode("ul",{class:"flex",id:"slider_"+t.Random_string},[t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_indicators_inside_slider"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["items-center justify-center hidden arrow_button xl:flex xxl:flex md:flex sm:flex",o.direction_property=="rtl"?"arrow_button_next":"arrow_button_prev"])},[e.createElementVNode("div",Ao,[e.createElementVNode("button",{class:"p-3 rounded-full shadow-lg arrow_button_styles",onClick:r[1]||(r[1]=e.withModifiers(i=>n.prev(),["stop"]))},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",Mo,Lo)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",Io,zo)):e.createCommentVNode("",!0)])])],2)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},void 0,!0),t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_indicators_inside_slider"?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["items-center justify-center hidden xl:flex xxl:flex md:flex sm:flex arrow_button",o.direction_property=="rtl"?"arrow_button_prev":"arrow_button_next"])},[e.createElementVNode("div",Go,[e.createElementVNode("button",{class:"p-3 rounded-full shadow-lg arrow_button_styles",onClick:r[2]||(r[2]=e.withModifiers(i=>n.next(),["stop"]))},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",Fo,Uo)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",Ro,qo)):e.createCommentVNode("",!0)])])],2)):e.createCommentVNode("",!0)],8,jo),o.slider_arrows_indicators_position!="arrows_indicators_below_slider"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["flex justify-center mb-1 space-x-1",n.sliderIndicatorsAction()])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dotsNum,i=>(e.openBlock(),e.createElementBlock("button",{role:"button",class:e.normalizeClass(["gl-dot",{active:t.currentDot==i}]),key:i,onClick:s=>n.setDot(i)},Zo,10,Ho))),128))],2)):e.createCommentVNode("",!0),o.slider_arrows_indicators_position=="arrows_indicators_below_slider"?(e.openBlock(),e.createElementBlock("div",Ko,[e.createElementVNode("div",{class:e.normalizeClass(["flex justify-center mb-1 space-x-1",n.sliderIndicatorsAction()])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dotsNum,i=>(e.openBlock(),e.createElementBlock("button",{role:"button",class:e.normalizeClass(["gl-dot",{active:t.currentDot==i}]),key:i,onClick:s=>n.setDot(i)},Wo,10,vo))),128))],2),t.dotsNum>0?(e.openBlock(),e.createElementBlock("div",Yo,[e.createElementVNode("div",Xo,[e.createElementVNode("div",Jo,[e.createElementVNode("button",{class:e.normalizeClass(["p-3 rounded-full arrow_button_styles",o.direction_property=="rtl"?"ml-3":"mr-3"]),onClick:r[3]||(r[3]=i=>n.prev())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",Qo,en)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",tn,rn)):e.createCommentVNode("",!0)],2)])]),e.createElementVNode("div",on,[e.createElementVNode("div",nn,[e.createElementVNode("button",{class:"p-3 rounded-full arrow_button_styles",onClick:r[4]||(r[4]=i=>n.next())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",an,ln)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",sn,dn)):e.createCommentVNode("",!0)])])])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],10,Po),t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_outside_slider"?(e.openBlock(),e.createElementBlock("div",cn,[e.createElementVNode("div",mn,[e.createElementVNode("button",{class:"p-3 ml-5 rounded-full shadow-lg arrow_button_styles",onClick:r[5]||(r[5]=i=>n.next())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",gn,fn)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",hn,un)):e.createCommentVNode("",!0)])])])):e.createCommentVNode("",!0)],10,Bo)])}const yn=k(Vo,[["render",pn],["__scopeId","data-v-a94f16a9"]]),bn={class:"fixed left-0 top-13 z-[1055] h-full w-full overflow-y-auto overflow-x-hidden outline-none inset-0 bg-black bg-opacity-80",tabindex:"-1","aria-hidden":"true"},_n={class:"pointer-events-auto relative flex max-h-[100%] w-full flex-col overflow-hidden text-current shadow-4 outline-none bg-white border rounded-lg border-stroke dark:border-strokedark dark:bg-boxdark"},kn={class:"flex items-center justify-between flex-shrink-0 pt-10 pb-3 pl-3 pr-3 border-b-2 dark:border-gray-600"},xn={class:"text-xl font-medium leading-normal text-surface dark:text-white"},wn=[e.createElementVNode("span",{class:"[&>svg]:h-6 [&>svg]:w-6"},[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M6 18L18 6M6 6l12 12"})])],-1)],En={class:"flex flex-wrap items-center justify-end flex-shrink-0 p-4 border-t-2 rounded-b-md border-neutral-100 dark:border-gray-600"},Nn={__name:"GlModal",props:{is_open:{type:Boolean,default:!1},title:{type:String,default:""},max_width:{type:String,default:"max-w-2xl"},bodyClass:{type:String,default:"p-4"}},emits:["closeModal"],setup(t,{emit:r}){const o=t,a=r,l=()=>{document.documentElement.style.overflow="hidden",document.documentElement.style.paddingRight="0px"},n=()=>{document.documentElement.style.overflow="",document.documentElement.style.paddingRight=""},i=()=>{a("closeModal"),n()};return e.watch(()=>o.is_open,(s,d)=>{s?l():n()},{immediate:!0,deep:!0}),(s,d)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",bn,[e.createElementVNode("div",{class:e.normalizeClass(["pointer-events-none relative h-[calc(100%-1rem)] w-auto translate-y-[-50px] transition-all duration-300 ease-in-out min-[576px]:mx-auto min-[576px]:mt-7 min-[576px]:h-[calc(100%-3.5rem)]",t.max_width])},[e.createElementVNode("div",_n,[e.createElementVNode("div",kn,[e.createElementVNode("h5",xn,e.toDisplayString(t.title),1),e.createElementVNode("button",{type:"button",class:"box-content border-none rounded-none text-neutral-500 hover:text-neutral-800 hover:no-underline focus:text-neutral-800 focus:opacity-100 focus:shadow-none focus:outline-none dark:text-neutral-400 dark:hover:text-neutral-300 dark:focus:text-neutral-300",onClick:i,"aria-label":"Close"},wn)]),e.createElementVNode("div",{class:e.normalizeClass(["relative overflow-y-auto",t.bodyClass])},[e.renderSlot(s.$slots,"body")],2),e.createElementVNode("div",En,[e.renderSlot(s.$slots,"buttons"),e.createElementVNode("button",{onClick:i,type:"button",class:"px-5 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-200 rounded-lg ms-3 hover:bg-gray-100 focus:ring-4 focus:outline-none focus:ring-blue-300 hover:text-gray-900 focus:z-10 dark:bg-gray-700 dark:text-gray-300 dark:border-gray-500 dark:hover:text-white dark:hover:bg-gray-600 dark:focus:ring-gray-600"}," Close ")])])],2)],512)),[[e.vShow,t.is_open]])}},Vn={class:"flex justify-between p-2 -mb-px border border-gray-300 no-underlin"},Bn={class:"relative inline-flex items-center cursor-pointer"},Cn=["name","id","checked"],$n=e.createElementVNode("div",{class:"w-11 h-6 bg-gray-200 peer-focus:outline-none peer-focus:ring-4 peer-focus:ring-blue-300 dark:peer-focus:ring-blue-800 rounded-full peer dark:bg-gray-700 peer-checked:after:translate-x-full rtl:peer-checked:after:-translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-[2px] after:start-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all dark:border-gray-600 peer-checked:bg-blue-600"},null,-1),Sn=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Dn={key:0,class:"flex justify-between items-center"},Tn={class:"gl-label-form"},On={class:"flex justify-between p-2 -mb-px border border-gray-200 rounded-lg no-underlin dark:border-gray-600 dark:focus:border-frontenddark"},Pn={class:"relative inline-flex items-center cursor-pointer"},jn=["name","id"],An=e.createElementVNode("div",{class:"w-11 h-6 bg-gray-200 peer-focus:outline-none peer-focus:ring-4 peer-focus:ring-blue-300 dark:peer-focus:ring-blue-800 rounded-full peer dark:bg-gray-700 peer-checked:after:translate-x-full rtl:peer-checked:after:-translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-[2px] after:start-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all dark:border-gray-600 peer-checked:bg-blue-600"},null,-1),Mn={class:"gl-span-form-error"},Ln={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},In={__name:"GlToggleBox",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:String,required:!0},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},has_label_up:{type:Boolean,default:!1},description:{type:String,default:""}},emits:["update:modelValue"],setup(t,{emit:r}){const o=t,a=r,l=e.ref(null),n=e.computed({get(){return o.modelValue},set(i){a("update:modelValue",i)}});return(i,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("div",null,[e.createElementVNode("li",Vn,[e.createTextVNode(e.toDisplayString(t.label_name)+" ",1),e.createElementVNode("label",Bn,[e.createElementVNode("input",{type:"checkbox",class:"sr-only peer",name:t.field_name,id:t.field_name,checked:t.modelValue,"true-value":1,"false-value":0,ref_key:"input",ref:l,disabled:""},null,8,Cn),$n])])]),Sn],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(t.field_name)},[t.has_label_up?(e.openBlock(),e.createElementBlock("div",Dn,[e.createElementVNode("label",Tn,e.toDisplayString(t.label_name),1)])):e.createCommentVNode("",!0),e.createElementVNode("li",On,[e.createTextVNode(e.toDisplayString(t.label_name)+" ",1),e.createElementVNode("label",Pn,[e.withDirectives(e.createElementVNode("input",{type:"checkbox",class:"sr-only peer",name:t.field_name,id:t.field_name,"true-value":1,"false-value":0,ref_key:"input",ref:l,"onUpdate:modelValue":s[0]||(s[0]=d=>n.value=d)},null,8,jn),[[e.vModelCheckbox,n.value]]),An])]),e.createElementVNode("span",Mn,e.toDisplayString(t.error_message),1),e.createElementVNode("small",Ln,e.toDisplayString(t.description),1)],2))],64))}},zn={class:"font-bold ptext-lg dark:text-white"},Gn={class:"mt-3 mb-4"},Fn={class:"bg-blue-100 text-blue-800 text-sm font-medium mb-2 mt-2 me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},Un=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Rn=["name","id","value"],qn={key:0,class:"dropdown"},Hn={class:"focus:ring-blue-500 focus:border-blue-500 dark:border-gray-600 dark:focus:ring-blue-500 dark:focus:border-blue-500"},Zn={class:"relative showOptions"},Kn=["value","placeholder"],vn={class:"text-gray-700 bg-white dark:border-strokedark dark:bg-boxdark dark:text-gray-200 !border-b !border-t-0 !border-r !border-l absolute w-full z-[999999999]"},Wn={class:"p-1"},Yn=e.createElementVNode("label",{for:"default-search",class:"mb-2 text-sm font-medium text-gray-900 sr-only dark:text-white"},"Search",-1),Xn={class:"relative"},Jn=e.createElementVNode("div",{class:"absolute inset-y-0 flex items-center pointer-events-none start-0 ps-3"},[e.createElementVNode("svg",{class:"w-4 h-4 text-gray-500 dark:text-gray-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m19 19-4-4m0-7A7 7 0 1 1 1 8a7 7 0 0 1 14 0Z"})])],-1),Qn=["id"],ea={class:"overflow-y-auto max-h-64"},ta=["onClick","onMousedown","id"],ra={class:"flex items-center py-2 pl-10 pr-4"},oa={key:0,class:"absolute flex items-center flex-shrink-0 w-4 h-4 text-green-500 left-2 dark:text-green-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 12"},na=[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M1 5.917 5.724 10.5 15 1.5"},null,-1)],aa={class:"block mt-1 text-sm font-normal leading-5 text-red-500"},la={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},sa={__name:"GlDropdown",props:{modelValue:{type:[String,Number],default:""},defaultValue:{type:[String,Number],default:""},field_name:{type:String,default:""},is_required:{type:Boolean,default:!1},has_cancel:{type:Boolean,default:!0},label_name:{type:String,default:""},options:{type:Array,required:!0,default:()=>[],note:"Options of dropdown. An array of options with id and name"},placeholder:{type:String,required:!1,default:"Please select an option",note:"Placeholder of dropdown"},maxItem:{type:Number,required:!1,default:1e4,note:"Max items showing"},show:{type:Boolean,default:!1},error_message:{type:String,default:""},description:{type:String,default:""}},emits:["update:modelValue","selected","selectionChanged"],setup(t,{emit:r}){const o=t,a=r,l=e.ref(null),n=e.ref({}),i=e.ref(0),s=e.ref(!1),d=e.ref(""),c=e.ref("");e.onMounted(()=>{c.value=S(),o.show||(document.body.addEventListener("click",f=>{U(f)}),document.addEventListener("keypress",f=>{f.key==="Enter"&&f.target.form&&f.preventDefault()}))});const m=e.computed(()=>te()),h=e.computed(()=>re()),b=e.computed(()=>{const f=[],x=new RegExp(d.value,"ig");for(const E of m.value){const $=String(E.name);(d.value.length<1||$.match(x))&&f.length<o.maxItem&&f.push(E)}return f});function _(f){if(["ArrowLeft","ArrowUp","ArrowRight","ArrowDown","Enter"].includes(f.key)){if(["ArrowUp","ArrowDown"].includes(f.key)&&f.preventDefault(),f.key==="ArrowDown"&&o.posts==="")return;ee(f.key)}}function S(){let f=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(E){const $=(f+Math.random()*16)%16|0;return f=Math.floor(f/16),(E==="x"?$:$&3|8).toString(16)})}function j(f){return f!==null&&typeof f=="object"&&Object.keys(f).length>0}function U(f){f.target.id!=o.field_name+"search"+c.value&&f.target.id!=o.field_name&&!f.target.classList.contains("showOptions")&&(I(),i.value=0)}function A(f){const x=`${f}${c.value}`,E=document.getElementById(x);E&&E.scrollIntoView()}function Q(f){const x=`${f}${c.value}`,E=document.getElementById(x);E&&E.click()}function ee(f){f==="ArrowDown"&&i.value<b.value.length&&(i.value++,A(i.value)),f==="ArrowUp"&&i.value>1&&(i.value--,A(i.value)),f==="Enter"&&Q(i.value)}function te(){return o.options.map((f,x)=>typeof f=="object"?f:{id:f,name:f})}function re(){if(j(n.value))return typeof n.value=="object"?m.value.find(f=>String(f.id)===String(n.value.id))||{}:m.value.find(f=>String(f.id)===String(n.value))||{};if(o.modelValue)return typeof o.modelValue=="object"?m.value.find(f=>String(f.id)===String(o.modelValue.id))||{}:m.value.find(f=>String(f.id)===String(o.modelValue))||{}}function M(f){n.value=f,s.value=!1,a("update:modelValue",n.value.id),a("selected",n.value),a("selectionChanged",n.value)}function L(){o.show||(d.value="",s.value=!0,e.nextTick(()=>{var f=document.getElementById(`${o.field_name}search${c.value}`);f&&f.focus()}))}function oe(){o.show||(n.value={},d.value="",a("update:modelValue",""),L())}function I(){n.value.id||(n.value={},d.value=""),a("selected",n.value),s.value=!1}return e.watch(d,()=>{b.value.length===0&&(n.value={})}),e.watch(n,f=>{j(f)&&a("update:modelValue",f.id)}),(f,x)=>{var E,$,g;return e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",zn,e.toDisplayString(t.label_name),1),e.createElementVNode("p",Gn,[e.createElementVNode("span",Fn,e.toDisplayString((E=h.value)==null?void 0:E.name),1)]),Un],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("input",{type:"hidden",name:t.field_name,id:t.field_name,value:($=h.value)==null?void 0:$.id},null,8,Rn),t.options?(e.openBlock(),e.createElementBlock("div",qn,[t.label_name?(e.openBlock(),e.createElementBlock("label",{key:0,class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required})},e.toDisplayString(t.label_name),3)):e.createCommentVNode("",!0),e.createElementVNode("div",Hn,[e.createElementVNode("div",Zn,[e.createElementVNode("input",{class:e.normalizeClass([{"gl-input-form":t.error_message=="","gl-input-form-invalid":t.error_message!==""},"pl-8 pr-2 showOptions"]),ref:t.field_name,onClick:x[0]||(x[0]=u=>L()),value:(g=h.value)==null?void 0:g.name,placeholder:t.placeholder,autocomplete:"off",readonly:""},null,10,Kn),e.withDirectives(e.createElementVNode("i",{onClick:x[1]||(x[1]=e.withModifiers(u=>oe(),["stop"])),class:"absolute text-gray-500 cursor-pointer fas fa-times right-7 hover:text-gray-700 dark:hover:text-gray-800",style:{top:"13px"}},null,512),[[e.vShow,j(h.value)&&t.has_cancel]]),e.createElementVNode("i",{onClick:x[2]||(x[2]=u=>!s.value&&L()),class:e.normalizeClass([s.value?"fa-angle-up":"fa-angle-down","absolute text-xl text-gray-500 cursor-pointer fas right-2 hover:text-gray-700 dark:hover:text-gray-800 showOptions"]),style:{top:"11px"}},null,2)]),e.withDirectives(e.createElementVNode("div",vn,[e.createElementVNode("div",Wn,[Yn,e.createElementVNode("div",Xn,[Jn,e.withDirectives(e.createElementVNode("input",{type:"search","onUpdate:modelValue":x[3]||(x[3]=u=>d.value=u),ref:l.value,id:`${t.field_name}search${c.value}`,onKeydown:_,onBlur:x[4]||(x[4]=u=>I()),autocomplete:"off",class:"block w-full p-2 text-sm text-gray-900 border rounded-lg outline-none border-frontend ps-10 bg-gray-50 focus:border-frontend dark:bg-gray-700 dark:border-frontenddark dark:placeholder-frontenddark dark:text-white dark:focus:border-frontenddark",placeholder:"Search ..."},null,40,Qn),[[e.vModelText,d.value]])])]),e.createElementVNode("div",ea,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(u,y)=>{var w;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative px-2 py-2 text-xs leading-4 text-gray-700 no-underline cursor-pointer dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white",y+1==i.value?"bg-gray-100 dark:bg-gray-600":""]),onClick:R=>M(u),onMousedown:R=>M(u),key:y,id:`${y+1}${c.value}`},[e.createElementVNode("div",ra,[((w=h.value)==null?void 0:w.id)===u.id?(e.openBlock(),e.createElementBlock("svg",oa,na)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.name||u.id||"-"),1)])],42,ta)}),128))])],512),[[e.vShow,s.value]])])])):e.createCommentVNode("",!0),e.createElementVNode("span",aa,e.toDisplayString(t.error_message),1),e.createElementVNode("small",la,e.toDisplayString(t.description),1)],2))],64)}}},ia={class:"font-bold ptext-lg dark:text-white"},da=["id"],ca=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),ma=["for"],ga=["required","name","id","type","placeholder"],fa={class:"gl-span-form-error"},ha={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},ua={__name:"GlTextarea",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:""},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},description:{type:String,default:""},placeholder:{type:String,default:""}},emits:["update:modelValue","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null);e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus()});const i=e.computed({get(){return a.modelValue},set(s){l("update:modelValue",s)}});return r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",ia,e.toDisplayString(t.label_name),1),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,da),ca],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,ma),e.withDirectives(e.createElementVNode("textarea",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({" gl-textarea-form mt-4 ":t.error_message==""," gl-textarea-form-invalid mt-4 ":t.error_message!==""}),type:t.type,"onUpdate:modelValue":d[0]||(d[0]=c=>i.value=c),onKeydown:d[1]||(d[1]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,rows:"4",placeholder:t.placeholder},null,42,ga),[[e.vModelText,i.value]]),e.createElementVNode("span",fa,e.toDisplayString(t.error_message),1),e.createElementVNode("small",ha,e.toDisplayString(t.description),1)],2))],64))}},pa={compatConfig:{MODE:3},inheritAttrs:!1,emits:["pagination-change-page"],components:{RenderlessPagination:{emits:["pagination-change-page"],props:{data:{type:Object,default:()=>{}},limit:{type:Number,default:0}},computed:{isApiResource(){return!!this.data.meta},currentPage(){return this.isApiResource?this.data.meta.current_page:this.data.current_page},firstPageUrl(){return this.isApiResource?this.data.links.first:null},from(){return this.isApiResource?this.data.meta.from:this.data.from},lastPage(){return this.isApiResource?this.data.meta.last_page:this.data.last_page},lastPageUrl(){return this.isApiResource?this.data.links.last:null},nextPageUrl(){return this.isApiResource?this.data.links.next:this.data.next_page_url},perPage(){return this.isApiResource?this.data.meta.per_page:this.data.per_page},prevPageUrl(){return this.isApiResource?this.data.links.prev:this.data.prev_page_url},to(){return this.isApiResource?this.data.meta.to:this.data.to},total(){return this.isApiResource?this.data.meta.total:this.data.total},pageRange(){if(this.limit===-1)return 0;if(this.limit===0)return this.lastPage;for(var t=this.currentPage,r=this.lastPage,o=this.limit,a=t-o,l=t+o+1,n=[],i=[],s,d=1;d<=r;d++)(d===1||d===r||d>=a&&d<l)&&n.push(d);return n.forEach(function(c){s&&(c-s===2?i.push(s+1):c-s!==1&&i.push("...")),i.push(c),s=c}),i}},methods:{previousPage(){this.selectPage(this.currentPage-1)},nextPage(){this.selectPage(this.currentPage+1)},selectPage(t){t!=="..."&&this.$emit("pagination-change-page",t)}},render(){return this.$slots.default({data:this.data,limit:this.limit,computed:{isApiResource:this.isApiResource,currentPage:this.currentPage,firstPageUrl:this.firstPageUrl,from:this.from,lastPage:this.lastPage,lastPageUrl:this.lastPageUrl,nextPageUrl:this.nextPageUrl,perPage:this.perPage,prevPageUrl:this.prevPageUrl,to:this.to,total:this.total,pageRange:this.pageRange},prevButtonEvents:{click:t=>{t.preventDefault(),this.previousPage()}},nextButtonEvents:{click:t=>{t.preventDefault(),this.nextPage()}},pageButtonEvents:t=>({click:r=>{r.preventDefault(),this.selectPage(t)}})})}}},props:{data:{type:Object,default:()=>{}},limit:{type:Number,default:0},showDisabled:{type:Boolean,default:!1},size:{type:String,default:"default",validator:t=>["small","default","large"].indexOf(t)!==-1},align:{type:String,default:"left",validator:t=>["left","center","right"].indexOf(t)!==-1}},methods:{onPaginationChangePage(t){this.$emit("pagination-change-page",t)}},mounted(){}},ya={class:"flex flex-col items-center"},ba={key:0,class:"text-sm text-gray-700 dark:text-gray-400"},_a={class:"font-semibold text-gray-900 dark:text-white"},ka={class:"font-semibold text-gray-900 dark:text-white"},xa={class:"font-semibold text-gray-900 dark:text-white"},wa=["tabindex"],Ea=e.createElementVNode("span",{class:"sr-only"},"Previous",-1),Na=e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 1 1 5l4 4"})],-1),Va=["aria-current"],Ba=["tabindex"],Ca=e.createElementVNode("span",{class:"sr-only"},"Next",-1),$a=e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m1 9 4-4-4-4"})],-1);function Sa(t,r,o,a,l,n){const i=e.resolveComponent("RenderlessPagination");return e.openBlock(),e.createBlock(i,{data:o.data,limit:o.limit,onPaginationChangePage:n.onPaginationChangePage},{default:e.withCtx(s=>[e.createElementVNode("div",ya,[s.computed.total>s.computed.perPage?(e.openBlock(),e.createElementBlock("span",ba,[e.createTextVNode(" Showing "),e.createElementVNode("span",_a,e.toDisplayString(s.computed.from),1),e.createTextVNode(" to "),e.createElementVNode("span",ka,e.toDisplayString(s.computed.to),1),e.createTextVNode(" of "),e.createElementVNode("span",xa,e.toDisplayString(s.computed.total),1),e.createTextVNode(" Entries ")])):e.createCommentVNode("",!0),s.computed.total>s.computed.perPage?(e.openBlock(),e.createElementBlock("ul",e.mergeProps({key:1},t.$attrs,{class:["flex items-center h-8 -space-x-px text-sm",{"pagination-sm":o.size=="small","pagination-lg":o.size=="large","justify-content-center":o.align=="center","justify-content-end":o.align=="right"}]}),[s.computed.prevPageUrl||o.showDisabled?(e.openBlock(),e.createElementBlock("li",{key:0,class:e.normalizeClass(["flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 ms-0 border-e-0 rounded-s-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white",{disabled:!s.computed.prevPageUrl}])},[e.createElementVNode("a",e.mergeProps({class:"page-link",href:"#","aria-label":"Previous",tabindex:!s.computed.prevPageUrl&&-1},e.toHandlers(s.prevButtonEvents,!0)),[e.renderSlot(t.$slots,"prev-nav",{},()=>[Ea,Na])],16,wa)],2)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.computed.pageRange,(d,c)=>(e.openBlock(),e.createElementBlock("li",{class:e.normalizeClass(["",{active:d==s.computed.currentPage}]),key:c},[e.createElementVNode("a",e.mergeProps({class:"",href:"#"},e.toHandlers(s.pageButtonEvents(d),!0),{"aria-current":d==s.computed.currentPage?"page":null,class:d==s.computed.currentPage?"z-10 flex items-center justify-center px-3 h-8 leading-tight text-blue-600 border border-blue-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white":"flex items-center justify-center px-3 h-8 leading-tight text-gray-500 bg-white border border-gray-300 hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"}),e.toDisplayString(d),17,Va)],2))),128)),s.computed.nextPageUrl||o.showDisabled?(e.openBlock(),e.createElementBlock("li",{key:1,class:e.normalizeClass(["flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 rounded-e-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white",{disabled:!s.computed.nextPageUrl}])},[e.createElementVNode("a",e.mergeProps({class:"",href:"#","aria-label":"Next",tabindex:!s.computed.nextPageUrl&&-1},e.toHandlers(s.nextButtonEvents,!0)),[e.renderSlot(t.$slots,"next-nav",{},()=>[Ca,$a])],16,Ba)],2)):e.createCommentVNode("",!0)],16)):e.createCommentVNode("",!0)])]),_:3},8,["data","limit","onPaginationChangePage"])}const Ve=k(pa,[["render",Sa]]),Da={components:{TailwindPagination:Ve},props:{data:Array,columns:Array,get_item_url:String,xprops:Object,refreshData:Boolean},data(){return{isLoading:!1,isMounted:!1,limit:5,showDisabled:!1,size:"default",align:"left",search:"",isDropdownOpen:!1,itemLists:[],tableData:[],sortField:this.columns[0].field_name,sortOrder:"desc",pageOptions:[5,10,20,50],perPage:5,page:1}},emits:["editAction"],computed:{filteredData(){const t=this.search.toLowerCase();return this.sortData(this.data).filter(o=>Object.values(o).some(a=>a.toString().toLowerCase().includes(t)))}},methods:{editAction(t){this.$emit("editAction",t)},forDynCompIs(t){return typeof t=="object"?t:null},GetItemLists(t=1){this.isLoading=!0,this.page=t;const r={sort:this.sortField,order:this.sortOrder,s:this.search,limit:this.perPage,page:this.page};axios.get(this.xprops.route_get_data,{params:r}).then(o=>{this.itemLists=o.data,this.isLoading=!1}).catch(o=>{console.error(o),this.isLoading=!1})},updateSortColumn(t,r){r&&(t===this.sortField?this.sortOrder=this.sortOrder==="asc"?"desc":"asc":(this.sortField=t,this.sortOrder="asc"),this.GetItemLists(this.page))},handleSearch(){this.sortField=this.columns[0].field_name,this.sortOrder="asc",this.page=1,this.GetItemLists(this.page)}},mounted(){this.GetItemLists(),this.isMounted=!0},watch:{searchFilter(){this.filteredOptions.length===0?this.selected={}:this.selected=this.filteredOptions[0]},perPage(t){this.page=1,this.perPage=t,this.GetItemLists(this.page)},refreshData(t,r){this.isMounted&&t!==r&&this.GetItemLists()}}},Ta={class:"p-2"},Oa={class:"flex flex-col flex-wrap pb-4 space-y-4 xl:flex-row xl:items-center xl:justify-between flex-column sm:space-y-0"},Pa={class:"flex items-center gap-2"},ja=e.createElementVNode("span",{class:"font-medium"}," Show ",-1),Aa={style:{"margin-top":"9px"}},Ma=e.createElementVNode("span",{class:"font-medium"}," Entries ",-1),La=e.createElementVNode("label",{for:"table-search",class:"sr-only"},"Search",-1),Ia={class:"relative"},za=e.createElementVNode("div",{class:"absolute inset-y-0 left-0 flex items-center pointer-events-none rtl:inset-r-0 rtl:right-0 ps-3"},[e.createElementVNode("svg",{class:"w-5 h-5 text-gray-500 dark:text-gray-400","aria-hidden":"true",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z","clip-rule":"evenodd"})])],-1),Ga={class:"overflow-auto rounded-lg dark:text-gray-400 dark:bg-gray-800"},Fa={class:"w-full h-full max-w-full overflow-hidden bg-white border-separate xl:overflow-auto lg:border-collapse border-spacing-y-3 lg:border-spacing-y-0 dark:border-strokedark dark:bg-boxdark"},Ua={class:"hidden text-sm font-normal text-center text-gray-500 lg:table-header-group dark:border-strokedark bg-gray-50 dark:bg-gray-700 dark:text-gray-400"},Ra=["onClick"],qa={key:0,class:"ml-2"},Ha={key:0,class:"fa fa-arrow-up"},Za={key:1,class:"fa fa-arrow-down"},Ka={key:0},va=["colspan"],Wa=[e.createElementVNode("div",{role:"status",class:"p-4 space-y-4 border border-gray-200 divide-y divide-gray-200 rounded shadow animate-pulse dark:divide-gray-700 md:p-6 dark:border-gray-700"},[e.createElementVNode("div",{class:"flex items-center justify-between"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("span",{class:"sr-only"},"Loading...")],-1)],Ya=["data-label"],Xa={class:"overflow-auto max-h-40"},Ja={class:"flex items-center justify-between px-4 py-3 bg-white border-gray-200 sm:px-6 dark:text-gray-400 dark:bg-gray-800"};function Qa(t,r,o,a,l,n){const i=e.resolveComponent("dropdown"),s=e.resolveComponent("TailwindPagination");return e.openBlock(),e.createElementBlock("div",Ta,[e.createElementVNode("div",Oa,[e.createElementVNode("div",Pa,[ja,e.createElementVNode("div",Aa,[e.createVNode(i,{has_cancel:!1,options:l.pageOptions,modelValue:l.perPage,"onUpdate:modelValue":r[0]||(r[0]=d=>l.perPage=d),is_required:!1,field_name:"perPage",label_name:"",default_value:5,show:!1,placeholder:"Please select an option"},null,8,["options","modelValue"])]),Ma]),La,e.createElementVNode("div",Ia,[za,e.withDirectives(e.createElementVNode("input",{type:"text","onUpdate:modelValue":r[1]||(r[1]=d=>l.search=d),onInput:r[2]||(r[2]=d=>n.handleSearch()),class:"block w-full p-2 text-sm text-gray-900 border border-gray-300 rounded-lg ps-10 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500",placeholder:"Search ..."},null,544),[[e.vModelText,l.search]])])]),e.createElementVNode("div",Ga,[e.createElementVNode("table",Fa,[e.createElementVNode("thead",Ua,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(d,c)=>(e.openBlock(),e.createElementBlock("th",{key:c,onClick:m=>n.updateSortColumn(d.field_name,d.sortable),class:"w-full px-4 py-2 lg:w-2/12"},[e.createTextVNode(e.toDisplayString(d.field_label)+" ",1),l.sortField===d.field_name?(e.openBlock(),e.createElementBlock("span",qa,[l.sortOrder==="asc"?(e.openBlock(),e.createElementBlock("i",Ha)):(e.openBlock(),e.createElementBlock("i",Za))])):e.createCommentVNode("",!0)],8,Ra))),128))])]),e.createElementVNode("tbody",null,[l.isLoading?(e.openBlock(),e.createElementBlock("tr",Ka,[e.createElementVNode("td",{colspan:o.columns.length},Wa,8,va)])):e.createCommentVNode("",!0),l.isLoading?e.createCommentVNode("",!0):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(l.itemLists.data,(d,c)=>(e.openBlock(),e.createElementBlock("tr",{key:c,class:"bg-white dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600 hover:dark:text-gray-200 text-gray-500"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(m,h)=>(e.openBlock(),e.createElementBlock("td",{key:h,"data-label":m.field_label,class:"text-pretty before:content-[attr(data-label)] before:font-bold lg:before:content-none flex md:flex-row flex-col justify-between gap-2 lg:table-cell py-4 px-5 lg:py-2.5 lg:px-4 border dark:border-gray-700"},[e.createElementVNode("div",Xa,[m.tdComp?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.forDynCompIs(m.tdComp)),{key:0,row:d,field:m.field_name,xprops:o.xprops,tdProps:m.tdProps,onDeleteAction:r[3]||(r[3]=b=>n.GetItemLists()),onEditAction:b=>n.editAction(d)},null,40,["row","field","xprops","tdProps","onEditAction"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(d[m.field_name]),1)],64))])],8,Ya))),128))]))),128))])])]),e.createElementVNode("div",Ja,[e.createVNode(s,{class:"mt-3 mb-0",data:l.itemLists,limit:l.limit,size:l.size,align:l.align,onPaginationChangePage:n.GetItemLists},null,8,["data","limit","size","align","onPaginationChangePage"])])])}const el=k(Da,[["render",Qa]]),tl={components:{},props:{data:Array,columns:Array},data(){return{showNoOfEntries:[1,2,3,10,20,30,40],search:"",sortKey:"",sortOrder:1,currentPage:1,itemsPerPage:10,jumpToPage:"",maxDisplayedPages:10}},computed:{filteredData(){const t=this.search.toLowerCase();return this.sortData(this.data).filter(o=>Object.values(o).some(a=>a!=null&&a.toString().toLowerCase().includes(t)))},totalPages(){return Math.ceil(this.filteredData.length/this.itemsPerPage)},paginatedData(){const t=(this.currentPage-1)*this.itemsPerPage,r=t+this.itemsPerPage;return this.filteredData.slice(t,r)},displayedPageNumbers(){let t=Math.max(this.currentPage-Math.floor(this.maxDisplayedPages/2),1),r=t+this.maxDisplayedPages-1;return r>this.totalPages&&(r=this.totalPages,t=Math.max(r-this.maxDisplayedPages+1,1)),Array.from({length:r-t+1},(o,a)=>t+a)},firstItemIndex(){return this.itemsPerPage*(this.currentPage-1)+1},lastItemIndex(){const t=this.itemsPerPage*this.currentPage;return t>this.filteredData.length?this.filteredData.length:t}},methods:{handleItemsPerPageChange(t){this.itemsPerPage=t},goToPage(t){t>=1&&t<=this.totalPages&&(this.currentPage=t)},sort(t){t===this.sortKey?this.sortOrder*=-1:(this.sortKey=t,this.sortOrder=1)},sortData(t){return this.sortKey?t.slice().sort((r,o)=>(r[this.sortKey]<o[this.sortKey]?-1:1)*this.sortOrder):t},previousPage(){this.currentPage>1&&this.currentPage--},nextPage(){this.currentPage<this.totalPages&&this.currentPage++},firstPage(){this.currentPage=1},lastPage(){this.currentPage=this.totalPages},goToPage(t){t>=1&&t<=this.totalPages&&(this.currentPage=t)}}},rl={class:"p-2"},ol={class:"flex flex-wrap pb-4 space-y-4 md:items-center md:justify-between flex-column sm:flex-row sm:space-y-0"},nl={class:"flex items-center gap-2"},al=e.createElementVNode("span",{class:"font-medium"}," Show ",-1),ll={style:{"margin-top":"9px"}},sl=e.createElementVNode("span",{class:"font-medium"}," Entries ",-1),il=e.createElementVNode("label",{for:"table-search",class:"sr-only"},"Search",-1),dl={class:"relative"},cl=e.createElementVNode("div",{class:"absolute inset-y-0 left-0 flex items-center pointer-events-none rtl:inset-r-0 rtl:right-0 ps-3"},[e.createElementVNode("svg",{class:"w-5 h-5 text-gray-500 dark:text-gray-400","aria-hidden":"true",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z","clip-rule":"evenodd"})])],-1),ml={class:"overflow-auto rounded-lg dark:text-gray-400 dark:bg-gray-800"},gl={class:"w-full h-full max-w-full overflow-hidden bg-white border-separate xl:overflow-auto lg:border-collapse border-spacing-y-3 lg:border-spacing-y-0 dark:border-strokedark dark:bg-boxdark"},fl={class:"hidden text-sm font-normal text-center text-gray-700 lg:table-header-group dark:border-strokedark bg-gray-50 dark:bg-gray-700 dark:text-gray-400"},hl=["onClick"],ul={key:0,class:"ml-2"},pl={key:0,class:"fa fa-arrow-up"},yl={key:1,class:"fa fa-arrow-down"},bl=["data-label"],_l=["innerHTML"],kl={key:0,class:"flex items-center justify-between px-4 py-3 bg-white border-gray-200 sm:px-6 dark:text-gray-400 dark:bg-gray-800"},xl={class:"flex justify-between flex-1 sm:hidden"},wl=["disabled"],El=["disabled"],Nl={class:"hidden sm:flex sm:flex-1 sm:items-center sm:justify-between"},Vl={class:"text-sm text-gray-700 dark:text-gray-400"},Bl={class:"font-medium"},Cl={class:"font-medium"},$l={class:"font-medium"},Sl={"aria-label":"Page navigation"},Dl={class:"flex items-center h-8 -space-x-px text-sm"},Tl=["disabled"],Ol=[e.createElementVNode("span",{class:"sr-only"},"Previous",-1),e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 1 1 5l4 4"})],-1)],Pl=["onClick"],jl=["onClick"],Al=["disabled"],Ml=[e.createElementVNode("span",{class:"sr-only"},"Next",-1),e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m1 9 4-4-4-4"})],-1)];function Ll(t,r,o,a,l,n){const i=e.resolveComponent("dropdown");return e.openBlock(),e.createElementBlock("div",rl,[e.createElementVNode("div",ol,[e.createElementVNode("div",nl,[al,e.createElementVNode("div",ll,[e.createVNode(i,{has_cancel:!1,options:l.showNoOfEntries,modelValue:l.itemsPerPage,"onUpdate:modelValue":r[0]||(r[0]=s=>l.itemsPerPage=s),is_required:!1,field_name:"NoOfEntries",label_name:"",default_value:10,show:!1,placeholder:"Please select an option"},null,8,["options","modelValue"])]),sl]),il,e.createElementVNode("div",dl,[cl,e.withDirectives(e.createElementVNode("input",{type:"text","onUpdate:modelValue":r[1]||(r[1]=s=>l.search=s),class:"block p-2 text-sm text-gray-900 border border-gray-300 rounded-lg ps-10 w-80 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500",placeholder:"Search ..."},null,512),[[e.vModelText,l.search]])])]),e.createElementVNode("div",ml,[e.createElementVNode("table",gl,[e.createElementVNode("thead",fl,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(s,d)=>(e.openBlock(),e.createElementBlock("th",{key:d,onClick:c=>n.sort(s),class:"w-full px-4 py-2 lg:w-2/12"},[e.createTextVNode(e.toDisplayString(s)+" ",1),l.sortKey===s?(e.openBlock(),e.createElementBlock("span",ul,[l.sortOrder==="asc"?(e.openBlock(),e.createElementBlock("i",pl)):(e.openBlock(),e.createElementBlock("i",yl))])):e.createCommentVNode("",!0)],8,hl))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.paginatedData,(s,d)=>(e.openBlock(),e.createElementBlock("tr",{key:d,class:"bg-white dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600 hover:dark:text-gray-200 text-gray-500"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(c,m)=>(e.openBlock(),e.createElementBlock("td",{key:m,"data-label":c,class:"text-pretty before:content-[attr(data-label)] before:font-bold lg:before:content-none flex md:flex-row flex-col justify-between gap-2 lg:table-cell py-4 px-5 lg:py-2.5 lg:px-4 border dark:border-gray-700"},[e.createElementVNode("p",{class:"text-pretty",innerHTML:s[m]},null,8,_l)],8,bl))),128))]))),128))])])]),n.paginatedData.length>0?(e.openBlock(),e.createElementBlock("div",kl,[e.createElementVNode("div",xl,[e.createElementVNode("a",{href:"#",onClick:r[2]||(r[2]=(...s)=>n.previousPage&&n.previousPage(...s)),disabled:l.currentPage===1,class:"relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50"},"Previous",8,wl),e.createElementVNode("a",{href:"#",onClick:r[3]||(r[3]=(...s)=>n.nextPage&&n.nextPage(...s)),disabled:l.currentPage===n.totalPages,class:"relative inline-flex items-center px-4 py-2 ml-3 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50"},"Next",8,El)]),e.createElementVNode("div",Nl,[e.createElementVNode("div",null,[e.createElementVNode("p",Vl,[e.createTextVNode(" Showing "),e.createElementVNode("span",Bl,e.toDisplayString(n.firstItemIndex),1),e.createTextVNode(" to "),e.createElementVNode("span",Cl,e.toDisplayString(n.lastItemIndex),1),e.createTextVNode(" of "),e.createElementVNode("span",$l,e.toDisplayString(n.filteredData.length),1),e.createTextVNode(" entries ")])]),e.createElementVNode("div",null,[e.createElementVNode("nav",Sl,[e.createElementVNode("ul",Dl,[e.createElementVNode("li",null,[e.createElementVNode("a",{href:"#",onClick:r[4]||(r[4]=(...s)=>n.previousPage&&n.previousPage(...s)),disabled:l.currentPage===1,class:"flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 ms-0 border-e-0 rounded-s-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"},Ol,8,Tl)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.displayedPageNumbers,s=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},[e.createElementVNode("li",null,[l.currentPage!==s?(e.openBlock(),e.createElementBlock("a",{key:0,href:"#",onClick:d=>n.goToPage(s),class:"flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"},e.toDisplayString(s),9,Pl)):e.createCommentVNode("",!0)]),e.createElementVNode("li",null,[l.currentPage===s?(e.openBlock(),e.createElementBlock("a",{key:0,href:"#",onClick:d=>n.goToPage(s),"aria-current":"page",class:"z-10 flex items-center justify-center h-8 px-3 leading-tight text-blue-600 border border-blue-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white"},e.toDisplayString(s),9,jl)):e.createCommentVNode("",!0)])],64))),128)),e.createElementVNode("li",null,[e.createElementVNode("a",{href:"#",onClick:r[5]||(r[5]=(...s)=>n.nextPage&&n.nextPage(...s)),disabled:l.currentPage===n.totalPages,class:"flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 rounded-e-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"},Ml,8,Al)])])])])])])):e.createCommentVNode("",!0)])}const Il=k(tl,[["render",Ll]]),zl={class:"flex items-center p-4 text-gray-500 bg-white rounded-lg shadow dark:bg-gray-800 dark:text-gray-400",role:"alert"},Gl={key:0,class:"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-green-500 bg-green-100 rounded-lg dark:bg-green-800 dark:text-green-200"},Fl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5Zm3.707 8.207-4 4a1 1 0 0 1-1.414 0l-2-2a1 1 0 0 1 1.414-1.414L9 10.586l3.293-3.293a1 1 0 0 1 1.414 1.414Z"})],-1),e.createElementVNode("span",{class:"sr-only"},"Check icon",-1)],Ul={key:1,class:"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-red-500 bg-red-100 rounded-lg dark:bg-red-800 dark:text-red-200"},Rl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5Zm3.707 11.793a1 1 0 1 1-1.414 1.414L10 11.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L8.586 10 6.293 7.707a1 1 0 0 1 1.414-1.414L10 8.586l2.293-2.293a1 1 0 0 1 1.414 1.414L11.414 10l2.293 2.293Z"})],-1),e.createElementVNode("span",{class:"sr-only"},"Error icon",-1)],ql={key:2,class:"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-orange-500 bg-orange-100 rounded-lg dark:bg-orange-700 dark:text-orange-200"},Hl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5ZM10 15a1 1 0 1 1 0-2 1 1 0 0 1 0 2Zm1-4a1 1 0 0 1-2 0V6a1 1 0 0 1 2 0v5Z"})],-1),e.createElementVNode("span",{class:"sr-only"},"Warning icon",-1)],Zl={class:"ml-3 text-sm font-normal"},Kl=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{"aria-hidden":"true",class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)],vl={__name:"ToastListItem",props:{message:String,duration:{type:Number,default:2e3},type:{type:String,default:"success"}},emits:["remove"],setup(t,{emit:r}){const o=t;e.onMounted(()=>{setTimeout(()=>a("remove"),o.duration)});const a=r;return(l,n)=>(e.openBlock(),e.createElementBlock("div",zl,[o.type==="success"?(e.openBlock(),e.createElementBlock("div",Gl,Fl)):e.createCommentVNode("",!0),o.type==="error"?(e.openBlock(),e.createElementBlock("div",Ul,Rl)):e.createCommentVNode("",!0),o.type==="warning"?(e.openBlock(),e.createElementBlock("div",ql,Hl)):e.createCommentVNode("",!0),e.createElementVNode("div",Zl,e.toDisplayString(o.message),1),e.createElementVNode("button",{onClick:n[0]||(n[0]=i=>a("remove")),type:"button",class:"-mx-1.5 -my-1.5 ml-auto inline-flex h-8 w-8 rounded-lg bg-white p-1.5 text-gray-400 hover:bg-gray-100 hover:text-gray-900 focus:ring-2 focus:ring-gray-300 dark:bg-gray-800 dark:text-gray-500 dark:hover:bg-gray-700 dark:hover:text-white","data-dismiss-target":"#toast-default","aria-label":"Close"},Kl)]))}},X=e.reactive({items:[]}),J={state:X,methods:{add(t){X.items.unshift({key:Symbol(),message:t.message,type:t.type,duration:t.duration})},remove(t){X.items.splice(t,1)}}},Wl={__name:"GlToastList",setup(t){function r(o){J.methods.remove(o)}return(o,a)=>(e.openBlock(),e.createBlock(e.TransitionGroup,{tag:"div","enter-from-class":"translate-x-full opacity-0","enter-active-class":"duration-500","leave-active-class":"duration-500","leave-to-class":"translate-x-full opacity-0",class:"fixed z-50 w-full max-w-xs space-y-4 top-4 right-4"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(J).state.items,(l,n)=>(e.openBlock(),e.createBlock(vl,{key:l.key,message:l.message,type:l.type,duration:l.duration,onRemove:i=>r(n)},null,8,["message","type","duration","onRemove"]))),128))]),_:1}))}},Yl={key:0,class:"flex justify-center"},Xl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 4 15"},[e.createElementVNode("path",{d:"M3.5 1.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 6.041a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 5.959a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z"})],-1)],Jl={class:"absolute right-0 z-10 mt-5 origin-top-right bg-white divide-y divide-gray-100 rounded-lg shadow w-44 dark:bg-gray-700 dark:divide-gray-600"},Ql={class:"py-2 text-sm text-gray-700 dark:text-gray-200","aria-labelledby":"dropdownDividerButton"},es={key:0},ts=["href"],rs=e.createElementVNode("i",{class:"mr-2 fa-solid fa-list-ul opacity-80"},null,-1),os={key:1},ns=e.createElementVNode("i",{class:"mr-2 fa-solid fa-trash-can opacity-80"},null,-1),as={__name:"DatatableAction",props:{field:{type:String,default:""},route_url:{type:String,default:""},row:{type:[Array,Object],default:[]},xprops:{type:Object,default:{}},tdProps:{type:Object,default:{}}},emits:["deleteAction"],setup(t,{emit:r}){const o=le(),a=t,l=e.ref(!1),n=e.ref(!1),i=()=>{l.value=!1},s=()=>{l.value=!0},d=()=>{n.value=!1},c=()=>{n.value=!0},m=r,h=()=>{axios.delete(`${a.xprops.route}/${a.row.id}`).then(()=>{d(),m("deleteAction"),o.commit("notification/SHOW_NOTIFICATION",{message:"Item deleted successfully.",type:"success",duration:5e3})}).catch(b=>{console.log(b)})};return(b,_)=>{const S=e.resolveDirective("click-outside");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(z,{isOpen:n.value,onConfirmDelete:h,onCancelDelete:d},null,8,["isOpen"]),t.row&&b.can(`edit_${t.xprops.permission} || delete_${t.xprops.permission}`)?e.withDirectives((e.openBlock(),e.createElementBlock("div",Yl,[e.createElementVNode("button",{onClick:s,class:"inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-white rounded-lg hover:bg-gray-100 focus:ring-4 focus:outline-none dark:text-white focus:ring-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-600",type:"button"},Xl),e.withDirectives(e.createElementVNode("div",Jl,[e.createElementVNode("ul",Ql,[b.can(`edit_${t.xprops.permission}`)?(e.openBlock(),e.createElementBlock("li",es,[e.createElementVNode("a",{href:t.xprops.route+"/"+t.row.id+"/edit",class:"block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"},[rs,e.createTextVNode(" Edit")],8,ts)])):e.createCommentVNode("",!0),b.can(`delete_${t.xprops.permission}`)?(e.openBlock(),e.createElementBlock("li",os,[e.createElementVNode("a",{href:"#",onClick:e.withModifiers(c,["prevent"]),class:"block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"},[ns,e.createTextVNode(" Remove")])])):e.createCommentVNode("",!0)])],512),[[e.vShow,l.value]])])),[[S,i]]):e.createCommentVNode("",!0)],64)}}},ls={key:0,class:"flex justify-center"},ss=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 4 15"},[e.createElementVNode("path",{d:"M3.5 1.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 6.041a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 5.959a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z"})],-1)],is={class:"absolute right-0 z-10 mt-5 origin-top-right bg-white divide-y divide-gray-100 rounded-lg shadow w-44 dark:bg-gray-700 dark:divide-gray-600"},ds={class:"py-2 text-sm text-gray-700 dark:text-gray-200","aria-labelledby":"dropdownDividerButton"},cs={key:0},ms=e.createElementVNode("i",{class:"mr-2 fa-solid fa-trash-can opacity-80"},null,-1),gs={__name:"DatatableDeleteAction",props:{field:{type:String,default:""},route_url:{type:String,default:""},row:{type:[Array,Object],default:[]},xprops:{type:Object,default:{}},tdProps:{type:Object,default:{}}},emits:["deleteAction"],setup(t,{emit:r}){const o=le(),a=t,l=e.ref(!1),n=e.ref(!1),i=()=>{l.value=!1},s=()=>{l.value=!0},d=()=>{n.value=!1},c=()=>{n.value=!0},m=r,h=()=>{axios.delete(`${a.xprops.route}/${a.row.id}`).then(()=>{d(),m("deleteAction"),o.commit("notification/SHOW_NOTIFICATION",{message:"Item deleted successfully.",type:"success",duration:5e3})}).catch(b=>{console.log(b)})};return(b,_)=>{const S=e.resolveDirective("click-outside");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(z,{isOpen:n.value,onConfirmDelete:h,onCancelDelete:d},null,8,["isOpen"]),t.row&&b.can(`delete_${t.xprops.permission}`)?e.withDirectives((e.openBlock(),e.createElementBlock("div",ls,[e.createElementVNode("button",{onClick:s,class:"inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-white rounded-lg hover:bg-gray-100 focus:ring-4 focus:outline-none dark:text-white focus:ring-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-600",type:"button"},ss),e.withDirectives(e.createElementVNode("div",is,[e.createElementVNode("ul",ds,[b.can(`delete_${t.xprops.permission}`)?(e.openBlock(),e.createElementBlock("li",cs,[e.createElementVNode("a",{href:"#",onClick:e.withModifiers(c,["prevent"]),class:"block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"},[ms,e.createTextVNode(" Remove")])])):e.createCommentVNode("",!0)])],512),[[e.vShow,l.value]])])),[[S,i]]):e.createCommentVNode("",!0)],64)}}},fs={props:["field","row"],computed:{isArray(){return Array.isArray(this.row)},isObject(){return typeof this.row=="object"},isString(){return typeof this.row=="string"}},mounted(){}},hs=["href","title"],us=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1),ps={key:1,class:"m-1 d-inline-block"},ys=["href","title"],bs=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1);function _s(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",null,[n.isArray?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(o.row,(i,s)=>(e.openBlock(),e.createElementBlock("div",{key:s,class:"m-1 d-inline-block"},[e.createElementVNode("a",{href:i,title:i,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[us,e.createTextVNode(" Download ")],8,hs)]))),128)):n.isString?(e.openBlock(),e.createElementBlock("div",ps,[e.createElementVNode("a",{href:o.row,title:o.row,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[bs,e.createTextVNode(" Download ")],8,ys)])):e.createCommentVNode("",!0)])}const ks=k(fs,[["render",_s]]),xs={props:["field","row"],computed:{isArray(){return Array.isArray(this.row[this.field])},isObject(){return typeof this.row[this.field]=="object"}}},ws=["href","title"],Es=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1),Ns={key:1,class:"m-1 d-inline-block"},Vs=["href","title"],Bs=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1);function Cs(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",null,[n.isArray?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(o.row[o.field],i=>(e.openBlock(),e.createElementBlock("div",{key:i.id,class:"m-1 d-inline-block"},[e.createElementVNode("a",{href:i.url,title:i.name,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[Es,e.createTextVNode(" Download ")],8,ws)]))),128)):n.isObject?(e.openBlock(),e.createElementBlock("div",Ns,[e.createElementVNode("a",{href:o.row[o.field].url,title:o.row[o.field].name,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[Bs,e.createTextVNode(" Download ")],8,Vs)])):e.createCommentVNode("",!0)])}const $s=k(xs,[["render",Cs]]),Ss={props:["field","row","tdProps"]},Ds={key:0},Ts=["innerHTML"];function Os(t,r,o,a,l,n){return o.row[o.field]?(e.openBlock(),e.createElementBlock("div",Ds,[e.createElementVNode("div",{class:"w-full",innerHTML:o.row[o.field]},null,8,Ts)])):e.createCommentVNode("",!0)}const Ps=k(Ss,[["render",Os]]),js={props:["field","row","tdProps"],computed:{entry(){const[t,r]=this.field.split(".");return e.markRaw({key:t,field:r})},isArray(){return Array.isArray(this.row[this.entry.key])},isObject(){return typeof this.row[this.entry.key]=="object"}}},As={class:"flex flex-wrap gap-2"},Ms={key:1,class:"px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded dark:bg-blue-900 dark:text-blue-300"};function Ls(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",As,[n.isArray?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(o.row[n.entry.key],(i,s)=>(e.openBlock(),e.createElementBlock("span",{key:s,class:"px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded dark:bg-blue-900 dark:text-blue-300"},e.toDisplayString(i[n.entry.field]),1))),128)):n.isObject?(e.openBlock(),e.createElementBlock("span",Ms,e.toDisplayString(o.row[n.entry.key][n.entry.field]),1)):e.createCommentVNode("",!0)])}const Is=k(js,[["render",Ls]]),zs={props:["field","row","tdProps"]},Gs={key:0},Fs={class:"m-1 d-inline-block"},Us=["href","title"],Rs=["src","alt","title"];function qs(t,r,o,a,l,n){return o.row[o.field]?(e.openBlock(),e.createElementBlock("div",Gs,[e.createElementVNode("div",Fs,[e.createElementVNode("a",{href:o.row[o.field].url,title:o.row[o.field].name,target:"_blank"},[e.createElementVNode("img",{src:o.row[o.field].thumbnail,alt:o.row[o.field].name,title:o.row[o.field].name},null,8,Rs)],8,Us)])])):e.createCommentVNode("",!0)}const Hs=k(zs,[["render",qs],["__scopeId","data-v-3a28c02c"]]),Zs={props:["field","row","tdProps"],computed:{isActive(){return this.row[this.field]===1}}},Ks={class:"flex flex-wrap gap-2 text-nowrap"},vs={key:0,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},Ws=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1),Ys={key:1,class:"inline-flex items-center bg-red-100 text-red-800 text-xs font-medium px-2.5 py-0.5 rounded-full dark:bg-red-900 dark:text-red-300"},Xs=e.createElementVNode("span",{class:"w-2 h-2 bg-red-500 rounded-full me-1"},null,-1);function Js(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",Ks,[n.isActive?(e.openBlock(),e.createElementBlock("span",vs,[Ws,e.createTextVNode(" Active ")])):n.isActive?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",Ys,[Xs,e.createTextVNode(" Inactive ")]))])}const Qs=k(Zs,[["render",Js]]),ei={props:["field","row","tdProps"],computed:{hasLabelColor(t){const r=this.tdProps.status_general_labels_color.find(o=>o.label===this.row[this.field]);return r?r.class:""}}},ti={class:"flex flex-wrap gap-2 text-nowrap"},ri={key:0,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},oi=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1),ni={key:1,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-red-800 bg-red-100 rounded-full dark:bg-red-900 dark:text-red-300"},ai=e.createElementVNode("span",{class:"w-2 h-2 bg-red-500 rounded-full me-1"},null,-1),li={key:2,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-yellow-800 bg-yellow-100 rounded-full dark:bg-gray-700 dark:text-yellow-300"},si=e.createElementVNode("span",{class:"w-2 h-2 bg-yellow-500 rounded-full me-1"},null,-1),ii={key:3,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded-full dark:bg-gray-700 dark:text-blue-400"},di=e.createElementVNode("span",{class:"w-2 h-2 bg-blue-500 rounded-full me-1"},null,-1),ci={key:4,class:"inline-flex items-center px-2 py-1 text-sm text-blue-800 bg-blue-100 rounded-full dark:bg-blue-900 dark:text-blue-300"},mi=e.createElementVNode("span",{class:"relative flex w-2 h-2 mr-1"},[e.createElementVNode("span",{class:"absolute inline-flex w-full h-full bg-blue-500 rounded-full animate-ping"}),e.createElementVNode("span",{class:"relative inline-flex w-2 h-2 bg-blue-500 rounded-full"})],-1);function gi(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",ti,[n.hasLabelColor=="green"?(e.openBlock(),e.createElementBlock("span",ri,[oi,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="red"?(e.openBlock(),e.createElementBlock("span",ni,[ai,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="yellow"?(e.openBlock(),e.createElementBlock("span",li,[si,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="default"?(e.openBlock(),e.createElementBlock("span",ii,[di,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="animate"?(e.openBlock(),e.createElementBlock("span",ci,[mi,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0)])}const fi=k(ei,[["render",gi]]),hi={props:["field","row","tdProps"],computed:{hasLabelColor(){return this.tdProps.specfic_color??""},badgeType(){switch(this.tdProps.badge_type){case"Default":return"rounded text-xs";case"Large":return"rounded text-sm ";case"Bordered":return"rounded text-xs border";case"Pills":return"rounded-full text-xs";default:return""}}}},ui={class:"flex flex-wrap gap-2 text-nowrap justify-center"};function pi(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",ui,[n.hasLabelColor=="Default"?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["bg-blue-100 text-blue-800 font-medium me-2 px-2.5 py-0.5 dark:bg-blue-900 dark:text-blue-300 border-blue-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Dark"?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(["bg-gray-100 text-gray-800 font-medium me-2 px-2.5 py-0.5 dark:bg-gray-700 dark:text-gray-300 border-gray-500",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Red"?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(["bg-red-100 text-red-800 font-medium me-2 px-2.5 py-0.5 dark:bg-red-900 dark:text-red-300 border-red-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Green"?(e.openBlock(),e.createElementBlock("span",{key:3,class:e.normalizeClass(["bg-green-100 text-green-800 font-medium me-2 px-2.5 py-0.5 dark:bg-green-900 dark:text-green-300 border-green-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Yellow"?(e.openBlock(),e.createElementBlock("span",{key:4,class:e.normalizeClass(["bg-yellow-100 text-yellow-800 font-medium me-2 px-2.5 py-0.5 dark:bg-yellow-900 dark:text-yellow-300 border-yellow-300",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Indigo"?(e.openBlock(),e.createElementBlock("span",{key:5,class:e.normalizeClass(["bg-indigo-100 text-indigo-800 font-medium me-2 px-2.5 py-0.5 dark:bg-indigo-900 dark:text-indigo-300 border-indigo-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Purple"?(e.openBlock(),e.createElementBlock("span",{key:6,class:e.normalizeClass(["bg-purple-100 text-purple-800 font-medium me-2 px-2.5 py-0.5 dark:bg-purple-900 dark:text-purple-300 border-purple-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Pink"?(e.openBlock(),e.createElementBlock("span",{key:7,class:e.normalizeClass(["bg-pink-100 text-pink-800 font-medium me-2 px-2.5 py-0.5 dark:bg-pink-900 dark:text-pink-300 border-pink-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0)])}const yi=k(hi,[["render",pi]]),bi={props:["field","row","tdProps"],computed:{hasLabelColor(t){const r=this.tdProps.status_general_labels_color.find(o=>o.text===this.row[this.field]);return r?r.class:""},getLabel(){const t=this.tdProps.status_general_labels_color.find(r=>r.text===this.row[this.field]);return t?t.label:""}}},_i={class:"flex flex-wrap gap-2 text-nowrap"},ki={key:0,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},xi=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1),wi={key:1,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-red-800 bg-red-100 rounded-full dark:bg-red-900 dark:text-red-300"},Ei=e.createElementVNode("span",{class:"w-2 h-2 bg-red-500 rounded-full me-1"},null,-1),Ni={key:2,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-yellow-800 bg-yellow-100 rounded-full dark:bg-gray-700 dark:text-yellow-300"},Vi=e.createElementVNode("span",{class:"w-2 h-2 bg-yellow-500 rounded-full me-1"},null,-1),Bi={key:3,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded-full dark:bg-gray-700 dark:text-blue-400"},Ci=e.createElementVNode("span",{class:"w-2 h-2 bg-blue-500 rounded-full me-1"},null,-1),$i={key:4,class:"inline-flex items-center px-2 py-1 text-sm text-blue-800 bg-blue-100 rounded-full dark:bg-blue-900 dark:text-blue-300"},Si=e.createElementVNode("span",{class:"relative flex w-2 h-2 mr-1"},[e.createElementVNode("span",{class:"absolute inline-flex w-full h-full bg-blue-500 rounded-full animate-ping"}),e.createElementVNode("span",{class:"relative inline-flex w-2 h-2 bg-blue-500 rounded-full"})],-1);function Di(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",_i,[n.hasLabelColor=="green"?(e.openBlock(),e.createElementBlock("span",ki,[xi,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="red"?(e.openBlock(),e.createElementBlock("span",wi,[Ei,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="yellow"?(e.openBlock(),e.createElementBlock("span",Ni,[Vi,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="default"?(e.openBlock(),e.createElementBlock("span",Bi,[Ci,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="animate"?(e.openBlock(),e.createElementBlock("span",$i,[Si,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0)])}const Ti=k(bi,[["render",Di]]),Oi={props:["field","row","tdProps"],computed:{formattedDate(){if(!this.row[this.field])return"";const t=new Date(this.row[this.field]),r=t.getFullYear(),o=t.toLocaleString("default",{month:"long"}),a=t.getDate();let l=t.getHours();const n=t.getMinutes(),i=t.getSeconds(),s=l>=12?"pm":"am";return l=l%12,l=l||12,`${o} ${a}, ${r}, ${l}:${n}:${i} ${s}`},isActive(){return this.row[this.field]===1}}},Pi={class:"w-full"};function ji(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",Pi,e.toDisplayString(n.formattedDate),1)}const Ai=k(Oi,[["render",ji]]),Mi={props:["field","row","tdProps"]},Li={class:"flex flex-wrap gap-2 text-nowrap"},Ii={key:0,class:"inline-flex items-center px-2 py-1 text-sm text-blue-800 bg-blue-100 rounded-full dark:bg-blue-900 dark:text-blue-300"},zi=e.createElementVNode("span",{class:"relative flex w-2 h-2 mr-1"},[e.createElementVNode("span",{class:"absolute inline-flex w-full h-full bg-blue-500 rounded-full animate-ping"}),e.createElementVNode("span",{class:"relative inline-flex w-2 h-2 bg-blue-500 rounded-full"})],-1),Gi={key:1,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-yellow-800 bg-yellow-100 rounded-full dark:bg-gray-700 dark:text-yellow-300"},Fi=e.createElementVNode("span",{class:"w-2 h-2 bg-yellow-500 rounded-full me-1"},null,-1),Ui={key:2,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},Ri=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1);function qi(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",Li,[o.row[o.field]===0?(e.openBlock(),e.createElementBlock("span",Ii,[zi,e.createTextVNode(" Provisioning")])):e.createCommentVNode("",!0),o.row[o.field]===2?(e.openBlock(),e.createElementBlock("span",Gi,[Fi,e.createTextVNode(" Paused ")])):e.createCommentVNode("",!0),o.row[o.field]===1?(e.openBlock(),e.createElementBlock("span",Ui,[Ri,e.createTextVNode(" Active ")])):e.createCommentVNode("",!0)])}const Hi=k(Mi,[["render",qi]]),Zi={props:["field","row","tdProps"]},Ki={key:0,class:"text-nowrap"},vi={class:"w-full h-full p-3 mx-0 mt-0 overflow-auto font-mono text-left break-words rounded cursor-default whitespace-nowrap console_styles"};function Wi(t,r,o,a,l,n){return o.row[o.field]?(e.openBlock(),e.createElementBlock("div",Ki,[e.createElementVNode("pre",vi," "+e.toDisplayString(o.row[o.field])+`
8
- `,1)])):e.createCommentVNode("",!0)}const Yi=k(Zi,[["render",Wi]]),Xi={props:["isOpen","title","button_text"],methods:{confirmAction(){this.$emit("confirm-action")},cancelAction(){this.$emit("cancel-action")}}},Ji={key:0,class:"fixed inset-0 z-50 overflow-y-auto",role:"dialog","aria-modal":"true"},Qi={class:"flex items-end justify-center min-h-screen px-4 pt-4 pb-20 text-center sm:block sm:p-0"},ed=e.createElementVNode("div",{class:"fixed inset-0 transition-opacity bg-gray-500 bg-opacity-75","aria-hidden":"true"},null,-1),td=e.createElementVNode("span",{class:"hidden sm:inline-block sm:align-middle sm:h-screen","aria-hidden":"true"},"​",-1),rd={class:"inline-block overflow-hidden text-left align-bottom transition-all transform bg-white rounded-lg shadow-xl sm:my-8 sm:align-middle sm:max-w-lg sm:w-full"},od={class:"px-4 pt-5 pb-4 bg-white sm:p-6 sm:pb-4"},nd={class:"sm:flex sm:items-start"},ad={class:"mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left"},ld={class:"text-lg font-medium leading-6 text-gray-900"},sd={class:"mt-2"},id={class:"px-4 py-3 bg-gray-50 sm:px-6 sm:flex sm:flex-row-reverse"};function dd(t,r,o,a,l,n){return o.isOpen?(e.openBlock(),e.createElementBlock("div",Ji,[e.createElementVNode("div",Qi,[ed,td,e.createElementVNode("div",rd,[e.createElementVNode("div",od,[e.createElementVNode("div",nd,[e.createElementVNode("div",ad,[e.createElementVNode("h3",ld,e.toDisplayString(o.title),1),e.createElementVNode("div",sd,[e.renderSlot(t.$slots,"default")])])])]),e.createElementVNode("div",id,[e.createElementVNode("button",{onClick:r[0]||(r[0]=(...i)=>n.confirmAction&&n.confirmAction(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 text-base font-medium text-white bg-red-600 border border-transparent rounded-md shadow-sm hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm"},e.toDisplayString(o.button_text),1),e.createElementVNode("button",{onClick:r[1]||(r[1]=(...i)=>n.cancelAction&&n.cancelAction(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 mt-3 text-base font-medium text-gray-700 bg-white border border-gray-300 rounded-md shadow-sm hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 sm:mt-0 sm:ml-3 sm:w-auto sm:text-sm"}," Cancel ")])])])])):e.createCommentVNode("",!0)}const cd=k(Xi,[["render",dd]]),md={class:"w-full"},gd={class:"mb-2 flex justify-between items-center"},fd={class:"text-sm font-medium text-gray-900 dark:text-white"},hd={class:"relative bg-gray-50 rounded-lg dark:bg-gray-700 p-4 h-auto"},ud={class:"overflow-auto max-h-32"},pd={class:"text-sm text-gray-500 dark:text-gray-400"},yd={class:"absolute top-2 end-2 bg-gray-50 dark:bg-gray-700"},bd={key:0,class:"inline-flex items-center"},_d=[e.createElementVNode("svg",{class:"w-3 h-3 me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 18 20"},[e.createElementVNode("path",{d:"M16 1h-3.278A1.992 1.992 0 0 0 11 0H7a1.993 1.993 0 0 0-1.722 1H2a2 2 0 0 0-2 2v15a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2Zm-3 14H5a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2Zm0-4H5a1 1 0 0 1 0-2h8a1 1 0 1 1 0 2Zm0-5H5a1 1 0 0 1 0-2h2V2h4v2h2a1 1 0 1 1 0 2Z"})],-1),e.createElementVNode("span",{class:"text-xs font-semibold"},"Copy",-1)],kd={key:1,class:"inline-flex items-center"},xd=[e.createElementVNode("svg",{class:"w-3 h-3 text-blue-700 dark:text-blue-500 me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 12"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M1 5.917 5.724 10.5 15 1.5"})],-1),e.createElementVNode("span",{class:"text-xs font-semibold text-blue-700 dark:text-blue-500"},"Copied",-1)],wd={class:"mt-2 text-sm text-gray-500 dark:text-gray-400"},Ed={__name:"GlCodeCopy",props:{label_name:{type:String,default:""},code:{type:String,default:""},description:{type:String,default:""}},setup(t){const r=t,o=e.ref(!1),a=n=>{navigator.clipboard.writeText(n).then(function(){o.value=!0,setTimeout(()=>{o.value=!1},2e3)}).catch(function(i){console.error("Error copying to clipboard: ",i)})},l=e.computed(()=>r.code);return(n,i)=>(e.openBlock(),e.createElementBlock("div",md,[e.createElementVNode("div",gd,[e.createElementVNode("p",fd,e.toDisplayString(t.label_name),1)]),e.createElementVNode("div",hd,[e.createElementVNode("div",ud,[e.createElementVNode("code",pd,e.toDisplayString(l.value),1)]),e.createElementVNode("div",yd,[e.createElementVNode("button",{onClick:i[0]||(i[0]=s=>a(l.value)),class:"text-gray-900 dark:text-gray-400 m-1 hover:bg-gray-100 dark:bg-gray-800 dark:border-gray-600 dark:hover:bg-gray-700 rounded-lg py-2 px-3 inline-flex items-center justify-center bg-white border-gray-200 border"},[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",bd,_d)),o.value?(e.openBlock(),e.createElementBlock("span",kd,xd)):e.createCommentVNode("",!0)])])]),e.createElementVNode("p",wd,e.toDisplayString(t.description),1)]))}},Nd={class:"w-full"},Vd={class:"flex justify-between items-center"},Bd={class:"gl-label-form"},Cd={class:"flex items-center"},$d={class:"flex-shrink-0 z-10 inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-gray-100 border border-gray-300 rounded-s-lg dark:bg-gray-600 dark:text-white dark:border-gray-600"},Sd={class:"relative w-full"},Dd=["value"],Td={key:0},Od=[e.createElementVNode("svg",{class:"w-4 h-4","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 18 20"},[e.createElementVNode("path",{d:"M16 1h-3.278A1.992 1.992 0 0 0 11 0H7a1.993 1.993 0 0 0-1.722 1H2a2 2 0 0 0-2 2v15a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2Zm-3 14H5a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2Zm0-4H5a1 1 0 0 1 0-2h8a1 1 0 1 1 0 2Zm0-5H5a1 1 0 0 1 0-2h2V2h4v2h2a1 1 0 1 1 0 2Z"})],-1)],Pd={key:1,class:"inline-flex items-center"},jd=[e.createElementVNode("svg",{class:"w-4 h-4","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 12"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M1 5.917 5.724 10.5 15 1.5"})],-1)],Ad={class:"mt-2 text-sm text-gray-500 dark:text-gray-400"},Md={__name:"GlTextCopy",props:{label_name:{type:String,default:""},text_name:{type:String,default:""},code:{type:String,default:""},description:{type:String,default:""}},setup(t){const r=t,o=e.ref(!1),a=n=>{navigator.clipboard.writeText(n).then(function(){o.value=!0,setTimeout(()=>{o.value=!1},2e3)}).catch(function(i){console.error("Error copying to clipboard: ",i)})},l=e.computed(()=>r.code);return(n,i)=>(e.openBlock(),e.createElementBlock("div",Nd,[e.createElementVNode("div",Vd,[e.createElementVNode("label",Bd,e.toDisplayString(t.label_name),1)]),e.createElementVNode("div",Cd,[e.createElementVNode("span",$d,e.toDisplayString(t.text_name),1),e.createElementVNode("div",Sd,[e.createElementVNode("input",{type:"text","aria-describedby":"helper-text-explanation",class:"bg-gray-50 border border-e-0 border-gray-300 text-gray-500 dark:text-gray-400 text-sm border-s-0 focus:ring-blue-500 focus:border-blue-500 block w-full p-2 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:focus:ring-blue-500 dark:focus:border-blue-500",value:l.value,readonly:"",disabled:""},null,8,Dd)]),e.createElementVNode("button",{style:{padding:".61rem"},onClick:i[0]||(i[0]=s=>a(l.value)),class:"flex-shrink-0 z-10 inline-flex items-center px-4 text-sm font-medium text-center text-white bg-blue-700 rounded-e-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800 border border-blue-700 dark:border-blue-600 hover:border-blue-800 dark:hover:border-blue-700",type:"button"},[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",Td,Od)),o.value?(e.openBlock(),e.createElementBlock("span",Pd,jd)):e.createCommentVNode("",!0)])]),e.createElementVNode("p",Ad,e.toDisplayString(t.description),1)]))}};p.DatatableStatusTextLabelGeneral=Ti,p.GLDatatableCommand=Yi,p.GLDatatableDateTime=Ai,p.GLDatatableStatusServer=Hi,p.GlButton=wr,p.GlCard=er,p.GlCodeCopy=Ed,p.GlConfirmationModal=cd,p.GlDataTable=Il,p.GlDataTableServerSide=el,p.GlDatatableAction=as,p.GlDatatableDeleteAction=gs,p.GlDatatableFileDownload=ks,p.GlDatatableFiles=$s,p.GlDatatableHtml=Ps,p.GlDatatableList=Is,p.GlDatatablePicture=Hs,p.GlDatatableStatus=Qs,p.GlDatatableStatusGeneral=fi,p.GlDatatableStatusSpecficColor=yi,p.GlDeleteConfirmationModal=z,p.GlDropdown=sa,p.GlFilesUpload=Mt,p.GlLanguageSelector=Wt,p.GlModal=Nn,p.GlMultiItemSlide=yn,p.GlMultiSelectDropdown=br,p.GlNotify=Rt,p.GlTab=No,p.GlTabsWrapper=ko,p.GlTailwindPagination=Ve,p.GlTextCopy=Md,p.GlTextInput=co,p.GlTextTranslate=to,p.GlTextarea=ua,p.GlTextareaTranslate=Pr,p.GlTinymceTranslate=qr,p.GlToast=J,p.GlToastList=Wl,p.GlToggleBox=In,Object.defineProperty(p,Symbol.toStringTag,{value:"Module"})});
7
+ `,42,Fr),e.createElementVNode("span",Ur,e.toDisplayString(t.error_message),1),e.createElementVNode("small",Rr,e.toDisplayString(t.description),1)],2))],64))}},Hr={class:"font-bold ptext-lg dark:text-white"},Zr=["name","id"],Kr=["id"],vr=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Wr=["for"],Yr=e.createElementVNode("span",{class:"language-label js-language-label bg-blue-100 text-blue-800 text-xs font-medium me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},null,-1),Xr=["name","id"],Jr=["required","name","id","type"],Qr={class:"gl-span-form-error"},eo={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},to={__name:"GlTextTranslate",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:null},modelValue:{type:[String,Number],default:""},model_value_translate:{type:[String,Object],default:null},modelValueTranslate:{type:[String,Object],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},get_field_translations:{type:String,default:""},description:{type:String,default:""},translatable:{type:Object,default:null}},emits:["update:modelValue","update:modelValueTranslate","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null),i=e.ref(null);return e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus(),a.model_value&&(l("update:modelValue",a.model_value),n.value.value=a.model_value),a.model_value_translate,a.translatable&&axios.post("/admin/get_field_translations",{model:a.translatable.model,row_id:a.translatable.row_id,field:a.translatable.field}).then(s=>{i.value.value=JSON.stringify(s.data),l("update:modelValueTranslate",JSON.stringify(s.data))}).catch(s=>{console.log(s)})}),r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",Hr,e.toDisplayString(t.label_name),1),e.withDirectives(e.createElementVNode("input",{type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",ref:"input_translate_s","onUpdate:modelValue":d[0]||(d[0]=c=>s.inputTranslateValue=c)},null,8,Zr),[[e.vModelText,s.inputTranslateValue]]),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,Kr),vr],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-translation-form":t.error_message=="","gl-label-translation-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,Wr),Yr,e.createElementVNode("input",{class:"mb-4",type:"hidden","data-i18n":"true",name:t.field_name+"_i18n",id:t.field_name+"_i18n",onInput:d[1]||(d[1]=c=>s.$emit("update:modelValueTranslate",c.target.value)),ref_key:"input_translate",ref:i},null,40,Xr),e.createElementVNode("input",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({" gl-input-form form-input-translation mt-2 ":t.error_message==""," gl-input-form-invalid form-input-translation mt-2 ":t.error_message!==""}),type:t.type,onInput:d[2]||(d[2]=c=>s.$emit("update:modelValue",c.target.value)),onKeydown:d[3]||(d[3]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n},null,42,Jr),e.createElementVNode("span",Qr,e.toDisplayString(t.error_message),1),e.createElementVNode("small",eo,e.toDisplayString(t.description),1)],2))],64))}},ro={class:"font-bold ptext-lg dark:text-white"},oo={class:"mb-4 text-base text-gray-900 dark:text-white"},no=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),ao=["for"],lo=["required","name","id","type","placeholder"],so={class:"gl-span-form-error"},io={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},co={__name:"GlTextInput",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:""},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},description:{type:String,default:""},placeholder:{type:String,default:""}},emits:["update:modelValue","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null);e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus()});const i=e.computed({get(){return a.modelValue},set(s){l("update:modelValue",s)}});return r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",ro,e.toDisplayString(t.label_name),1),e.createElementVNode("p",oo,e.toDisplayString(t.type=="password"?t.modelValue.replace(/./g,"*"):t.modelValue),1),no],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,ao),e.withDirectives(e.createElementVNode("input",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({"gl-input-form":t.error_message=="","gl-input-form-invalid":t.error_message!==""}),type:t.type,"onUpdate:modelValue":d[0]||(d[0]=c=>i.value=c),onKeydown:d[1]||(d[1]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,placeholder:t.placeholder},null,42,lo),[[e.vModelDynamic,i.value]]),e.createElementVNode("span",so,e.toDisplayString(t.error_message),1),e.createElementVNode("small",io,e.toDisplayString(t.description),1)],2))],64))}},mo={setup(t,{slots:r}){const o=e.ref(r.default().map(l=>l.props)),a=e.ref(o.value[0].title);return e.provide("selectedTitle",a),{tabs:o,selectedTitle:a}}},go={class:"flex flex-wrap"},fo={class:"w-full"},ho={class:"flex flex-row flex-wrap gap-1 pt-3 pb-4 mb-0 list-none"},uo=["onClick"],po={class:"relative flex flex-col w-full min-w-0 mb-6 break-words bg-white rounded shadow-lg dark:border-strokedark dark:bg-boxdark"},yo={class:"flex-auto px-4 py-5"},bo={class:"tab-content tab-space"};function _o(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",go,[e.createElementVNode("div",fo,[e.createElementVNode("ul",ho,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.tabs,i=>(e.openBlock(),e.createElementBlock("li",{key:i.title,onClick:s=>a.selectedTitle=i.title,class:"flex-auto -mb-px text-center"},[e.createElementVNode("a",{class:e.normalizeClass([{"text-slate-600 bg-white dark:bg-meta-4":a.selectedTitle!=i.title,"text-white bg-slate-600 dark:bg-primary":a.selectedTitle===i.title},"block px-5 py-3 text-xs font-bold leading-normal rounded shadow-lg hover:text-white tex hover:bg-slate-600 dark:hover:bg-primary dark:text-white tabs_buttons"])},[e.createElementVNode("i",{class:e.normalizeClass([i.icon,"mr-1 text-base"])},null,2),e.createTextVNode(" "+e.toDisplayString(i.title),1)],2)],8,uo))),128))])])]),e.createElementVNode("div",po,[e.createElementVNode("div",yo,[e.createElementVNode("div",bo,[e.renderSlot(t.$slots,"default")])])])],64)}const ko=k(mo,[["render",_o]]),xo={props:["title"],setup(){return{selectedTitle:e.inject("selectedTitle")}}},wo={key:0,class:"block"};function Eo(t,r,o,a,l,n){return o.title==a.selectedTitle?(e.openBlock(),e.createElementBlock("div",wo,[e.renderSlot(t.$slots,"default")])):e.createCommentVNode("",!0)}const No=k(xo,[["render",Eo]]),Vo={props:{elements_to_show_prop:{type:Number,default:3},hide_arrow:{type:Boolean,default:!1},disable_touch:{type:Boolean,default:!1},direction_property:{type:String,default:"ltr"},slider_arrows_indicators_position:{type:String,default:"arrows_outside_slider"}},data:function(){return{elementsToShow:3,dotsNum:0,currentDot:1,dotsNavigation:[],touchStartX:0,isMoving:!1,initialX:0,initialY:0,Random_string:this.generateRandomString(6)}},mounted(){this.elementsToShow=this.elements_to_show_prop,this.initSlider(),this.disable_touch||this.movingActions()},methods:{sliderIndicatorsAction(){var t="";return this.direction_property=="rtl"?(t+=" space-x-reverse ",t+=" slider_indicators "):this.slider_arrows_indicators_position=="arrows_indicators_inside_slider"&&(t+=" slider_indicators "),t},sliderContainerAction(){var t="";return!this.hide_arrow&&this.slider_arrows_indicators_position=="arrows_outside_slider"?t+=" w-12/12 xl:w-8/12 xxl:w-8/12 md:w-8/12 sm:w-8/12":this.slider_arrows_indicators_position!="arrows_outside_slider"&&(t+=" w-12/12 "),t},generateRandomString(t){let r="";const o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",a=o.length;for(let l=0;l<t;l++)r+=o.charAt(Math.floor(Math.random()*a));return r},movingActions(){let t=this,r=document.getElementById("slider_"+this.Random_string);const o=l=>{r.style.cursor="grabbing";const n=s=>{const d=s.clientX||s.touches&&s.touches[0]&&s.touches[0].clientX,c=s.clientY||s.touches&&s.touches[0]&&s.touches[0].clientY,m=d-t.initialX,h=c-t.initialY;Math.abs(m)>Math.abs(h)?(s.preventDefault(),Math.abs(m)>=70&&(m<0?t.next():t.prev(),t.initialX=d)):r.style.cursor="grab",Math.abs(h)>Math.abs(m)&&(r.style.cursor="grab")},i=()=>{document.removeEventListener("mousemove",n),document.removeEventListener("touchmove",n),document.removeEventListener("mouseup",i),document.removeEventListener("touchend",i),r.style.cursor="grab"};document.addEventListener("mousemove",n),document.addEventListener("touchmove",n,{passive:!1}),document.addEventListener("mouseup",i),document.addEventListener("touchend",i),t.initialX=l.clientX||l.touches&&l.touches[0]&&l.touches[0].clientX,t.initialY=l.clientY||l.touches&&l.touches[0]&&l.touches[0].clientY},a=l=>{l.key==="ArrowLeft"?t.prev():l.key==="ArrowRight"&&t.next()};r.addEventListener("mousedown",o),r.addEventListener("touchstart",o),document.addEventListener("keydown",a)},next(){this.currentDot<this.dotsNavigation.length&&(this.currentDot++,this.setDot(this.currentDot))},prev(){this.currentDot>1&&(this.currentDot--,this.setDot(this.currentDot))},initSlider(){let t=document.getElementById("sliderContainer_"+this.Random_string),r=document.getElementById("mainSliderContainer_"+this.Random_string),o=document.getElementById("slider_"+this.Random_string),a=o.querySelectorAll("li"),l=Array.from(a).filter(s=>s.parentNode===o),n=t.clientWidth,i=n/this.elementsToShow;if(this.elementsToShow>1?document.body.clientWidth<1e3?(this.elementsToShow=1,i=this.hide_arrow?r.clientWidth:n):document.body.clientWidth<1500&&(this.elementsToShow=2):(this.elementsToShow=1,i=this.hide_arrow?r.clientWidth:n),l.length>1){this.dotsNum=this.elementsToShow==1?l.length:l.length-this.elementsToShow+1;let s=this.elementsToShow==1?i*l.length/this.dotsNum:i*(l.length-this.elementsToShow)/(this.dotsNum-1);this.dotsNavigation=[];for(let d=0;d<this.dotsNum;d++)this.dotsNavigation.push(s*d)}o.style.width=l.length*i+"px",o.style.transition="margin",o.style.transitionDuration="1s";for(let s=0;s<l.length;s++){const d=l[s];d.style.width=i+"px"}},setDot(t){let r=document.getElementById("slider_"+this.Random_string);this.direction_property=="rtl"?r.style.marginRight=-this.dotsNavigation[t-1]+"px":r.style.marginLeft=-this.dotsNavigation[t-1]+"px",this.currentDot=t}}},N=t=>(e.pushScopeId("data-v-a94f16a9"),t=t(),e.popScopeId(),t),Bo=["id"],Co={key:0,class:"items-center hidden w-2/12 xl:flex xxl:flex md:flex sm:flex arrow_button"},$o={class:"w-full"},So={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Do=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],To={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Oo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],Po=["id"],jo=["id"],Ao={class:"w-full"},Mo={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Lo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],Io={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},zo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],Go={class:"w-full"},Fo={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},Uo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],Ro={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},qo=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],Ho=["onClick"],Zo=[N(()=>e.createElementVNode("span",null,null,-1))],Ko={key:1,class:"flex justify-between pl-5 pr-5"},vo=["onClick"],Wo=[N(()=>e.createElementVNode("span",null,null,-1))],Yo={key:0,class:"flex"},Xo={class:"flex items-center"},Jo={class:"w-full"},Qo={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},en=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],tn={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},rn=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],on={class:"flex items-center"},nn={class:"w-full"},an={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},ln=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],sn={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},dn=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))],cn={key:1,class:"items-center hidden w-2/12 xl:flex xxl:flex md:flex sm:flex arrow_button"},mn={class:"w-full"},gn={key:0,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},fn=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M13 7l5 5m0 0l-5 5m5-5H6"},null,-1))],hn={key:1,xmlns:"http://www.w3.org/2000/svg",class:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},un=[N(()=>e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M11 17l-5-5m0 0l5-5m-5 5h12"},null,-1))];function pn(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",{class:e.normalizeClass(["",!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_outside_slide"?"flex":"relative block"]),id:"mainSliderContainer_"+t.Random_string},[t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_outside_slider"?(e.openBlock(),e.createElementBlock("div",Co,[e.createElementVNode("div",$o,[e.createElementVNode("button",{class:"p-3 mr-5 rounded-full shadow-lg arrow_button_styles",onClick:r[0]||(r[0]=i=>n.prev())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",So,Do)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",To,Oo)):e.createCommentVNode("",!0)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["overflow-hidden",n.sliderContainerAction()]),id:"sliderContainer_"+t.Random_string},[e.createElementVNode("ul",{class:"flex",id:"slider_"+t.Random_string},[t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_indicators_inside_slider"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["items-center justify-center hidden arrow_button xl:flex xxl:flex md:flex sm:flex",o.direction_property=="rtl"?"arrow_button_next":"arrow_button_prev"])},[e.createElementVNode("div",Ao,[e.createElementVNode("button",{class:"p-3 rounded-full shadow-lg arrow_button_styles",onClick:r[1]||(r[1]=e.withModifiers(i=>n.prev(),["stop"]))},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",Mo,Lo)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",Io,zo)):e.createCommentVNode("",!0)])])],2)):e.createCommentVNode("",!0),e.renderSlot(t.$slots,"default",{},void 0,!0),t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_indicators_inside_slider"?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["items-center justify-center hidden xl:flex xxl:flex md:flex sm:flex arrow_button",o.direction_property=="rtl"?"arrow_button_prev":"arrow_button_next"])},[e.createElementVNode("div",Go,[e.createElementVNode("button",{class:"p-3 rounded-full shadow-lg arrow_button_styles",onClick:r[2]||(r[2]=e.withModifiers(i=>n.next(),["stop"]))},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",Fo,Uo)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",Ro,qo)):e.createCommentVNode("",!0)])])],2)):e.createCommentVNode("",!0)],8,jo),o.slider_arrows_indicators_position!="arrows_indicators_below_slider"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["flex justify-center mb-1 space-x-1",n.sliderIndicatorsAction()])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dotsNum,i=>(e.openBlock(),e.createElementBlock("button",{role:"button",class:e.normalizeClass(["gl-dot",{active:t.currentDot==i}]),key:i,onClick:s=>n.setDot(i)},Zo,10,Ho))),128))],2)):e.createCommentVNode("",!0),o.slider_arrows_indicators_position=="arrows_indicators_below_slider"?(e.openBlock(),e.createElementBlock("div",Ko,[e.createElementVNode("div",{class:e.normalizeClass(["flex justify-center mb-1 space-x-1",n.sliderIndicatorsAction()])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.dotsNum,i=>(e.openBlock(),e.createElementBlock("button",{role:"button",class:e.normalizeClass(["gl-dot",{active:t.currentDot==i}]),key:i,onClick:s=>n.setDot(i)},Wo,10,vo))),128))],2),t.dotsNum>0?(e.openBlock(),e.createElementBlock("div",Yo,[e.createElementVNode("div",Xo,[e.createElementVNode("div",Jo,[e.createElementVNode("button",{class:e.normalizeClass(["p-3 rounded-full arrow_button_styles",o.direction_property=="rtl"?"ml-3":"mr-3"]),onClick:r[3]||(r[3]=i=>n.prev())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",Qo,en)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",tn,rn)):e.createCommentVNode("",!0)],2)])]),e.createElementVNode("div",on,[e.createElementVNode("div",nn,[e.createElementVNode("button",{class:"p-3 rounded-full arrow_button_styles",onClick:r[4]||(r[4]=i=>n.next())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",an,ln)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",sn,dn)):e.createCommentVNode("",!0)])])])])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],10,Po),t.dotsNum>0&&!o.hide_arrow&&o.slider_arrows_indicators_position=="arrows_outside_slider"?(e.openBlock(),e.createElementBlock("div",cn,[e.createElementVNode("div",mn,[e.createElementVNode("button",{class:"p-3 ml-5 rounded-full shadow-lg arrow_button_styles",onClick:r[5]||(r[5]=i=>n.next())},[o.direction_property=="ltr"?(e.openBlock(),e.createElementBlock("svg",gn,fn)):e.createCommentVNode("",!0),o.direction_property=="rtl"?(e.openBlock(),e.createElementBlock("svg",hn,un)):e.createCommentVNode("",!0)])])])):e.createCommentVNode("",!0)],10,Bo)])}const yn=k(Vo,[["render",pn],["__scopeId","data-v-a94f16a9"]]),bn={class:"fixed left-0 top-13 z-[1055] h-full w-full overflow-y-auto overflow-x-hidden outline-none inset-0 bg-black bg-opacity-80",tabindex:"-1","aria-hidden":"true"},_n={class:"pointer-events-auto relative flex max-h-[100%] w-full flex-col overflow-hidden text-current shadow-4 outline-none bg-white border rounded-lg border-stroke dark:border-strokedark dark:bg-boxdark"},kn={class:"flex items-center justify-between flex-shrink-0 pt-10 pb-3 pl-3 pr-3 border-b-2 dark:border-gray-600"},xn={class:"text-xl font-medium leading-normal text-surface dark:text-white"},wn=[e.createElementVNode("span",{class:"[&>svg]:h-6 [&>svg]:w-6"},[e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"},[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M6 18L18 6M6 6l12 12"})])],-1)],En={class:"flex flex-wrap items-center justify-end flex-shrink-0 p-4 border-t-2 rounded-b-md border-neutral-100 dark:border-gray-600"},Nn={__name:"GlModal",props:{is_open:{type:Boolean,default:!1},title:{type:String,default:""},max_width:{type:String,default:"max-w-2xl"},bodyClass:{type:String,default:"p-4"}},emits:["closeModal"],setup(t,{emit:r}){const o=t,a=r,l=()=>{document.documentElement.style.overflow="hidden",document.documentElement.style.paddingRight="0px"},n=()=>{document.documentElement.style.overflow="",document.documentElement.style.paddingRight=""},i=()=>{a("closeModal"),n()};return e.watch(()=>o.is_open,(s,d)=>{s?l():n()},{immediate:!0,deep:!0}),(s,d)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",bn,[e.createElementVNode("div",{class:e.normalizeClass(["pointer-events-none relative h-[calc(100%-1rem)] w-auto translate-y-[-50px] transition-all duration-300 ease-in-out min-[576px]:mx-auto min-[576px]:mt-7 min-[576px]:h-[calc(100%-3.5rem)]",t.max_width])},[e.createElementVNode("div",_n,[e.createElementVNode("div",kn,[e.createElementVNode("h5",xn,e.toDisplayString(t.title),1),e.createElementVNode("button",{type:"button",class:"box-content border-none rounded-none text-neutral-500 hover:text-neutral-800 hover:no-underline focus:text-neutral-800 focus:opacity-100 focus:shadow-none focus:outline-none dark:text-neutral-400 dark:hover:text-neutral-300 dark:focus:text-neutral-300",onClick:i,"aria-label":"Close"},wn)]),e.createElementVNode("div",{class:e.normalizeClass(["relative overflow-y-auto",t.bodyClass])},[e.renderSlot(s.$slots,"body")],2),e.createElementVNode("div",En,[e.renderSlot(s.$slots,"buttons"),e.createElementVNode("button",{onClick:i,type:"button",class:"px-5 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-200 rounded-lg ms-3 hover:bg-gray-100 focus:ring-4 focus:outline-none focus:ring-blue-300 hover:text-gray-900 focus:z-10 dark:bg-gray-700 dark:text-gray-300 dark:border-gray-500 dark:hover:text-white dark:hover:bg-gray-600 dark:focus:ring-gray-600"}," Close ")])])],2)],512)),[[e.vShow,t.is_open]])}},Vn={class:"flex justify-between p-2 -mb-px border border-gray-300 no-underlin"},Bn={class:"relative inline-flex items-center cursor-pointer"},Cn=["name","id","checked"],$n=e.createElementVNode("div",{class:"w-11 h-6 bg-gray-200 peer-focus:outline-none peer-focus:ring-4 peer-focus:ring-blue-300 dark:peer-focus:ring-blue-800 rounded-full peer dark:bg-gray-700 peer-checked:after:translate-x-full rtl:peer-checked:after:-translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-[2px] after:start-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all dark:border-gray-600 peer-checked:bg-blue-600"},null,-1),Sn=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Dn={key:0,class:"flex justify-between items-center"},Tn={class:"gl-label-form"},On={class:"flex justify-between p-2 -mb-px border border-gray-200 rounded-lg no-underlin dark:border-gray-600 dark:focus:border-frontenddark"},Pn={class:"relative inline-flex items-center cursor-pointer"},jn=["name","id"],An=e.createElementVNode("div",{class:"w-11 h-6 bg-gray-200 peer-focus:outline-none peer-focus:ring-4 peer-focus:ring-blue-300 dark:peer-focus:ring-blue-800 rounded-full peer dark:bg-gray-700 peer-checked:after:translate-x-full rtl:peer-checked:after:-translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-[2px] after:start-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all dark:border-gray-600 peer-checked:bg-blue-600"},null,-1),Mn={class:"gl-span-form-error"},Ln={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},In={__name:"GlToggleBox",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:String,required:!0},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},has_label_up:{type:Boolean,default:!1},description:{type:String,default:""}},emits:["update:modelValue"],setup(t,{emit:r}){const o=t,a=r,l=e.ref(null),n=e.computed({get(){return o.modelValue},set(i){a("update:modelValue",i)}});return(i,s)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("div",null,[e.createElementVNode("li",Vn,[e.createTextVNode(e.toDisplayString(t.label_name)+" ",1),e.createElementVNode("label",Bn,[e.createElementVNode("input",{type:"checkbox",class:"sr-only peer",name:t.field_name,id:t.field_name,checked:t.modelValue,"true-value":1,"false-value":0,ref_key:"input",ref:l,disabled:""},null,8,Cn),$n])])]),Sn],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(t.field_name)},[t.has_label_up?(e.openBlock(),e.createElementBlock("div",Dn,[e.createElementVNode("label",Tn,e.toDisplayString(t.label_name),1)])):e.createCommentVNode("",!0),e.createElementVNode("li",On,[e.createTextVNode(e.toDisplayString(t.label_name)+" ",1),e.createElementVNode("label",Pn,[e.withDirectives(e.createElementVNode("input",{type:"checkbox",class:"sr-only peer",name:t.field_name,id:t.field_name,"true-value":1,"false-value":0,ref_key:"input",ref:l,"onUpdate:modelValue":s[0]||(s[0]=d=>n.value=d)},null,8,jn),[[e.vModelCheckbox,n.value]]),An])]),e.createElementVNode("span",Mn,e.toDisplayString(t.error_message),1),e.createElementVNode("small",Ln,e.toDisplayString(t.description),1)],2))],64))}},zn={class:"font-bold ptext-lg dark:text-white"},Gn={class:"mt-3 mb-4"},Fn={class:"bg-blue-100 text-blue-800 text-sm font-medium mb-2 mt-2 me-2 px-2.5 py-0.5 rounded dark:bg-blue-900 dark:text-blue-300"},Un=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),Rn=["name","id","value"],qn={key:0,class:"dropdown"},Hn={class:"focus:ring-blue-500 focus:border-blue-500 dark:border-gray-600 dark:focus:ring-blue-500 dark:focus:border-blue-500"},Zn={class:"relative showOptions"},Kn=["value","placeholder"],vn={class:"text-gray-700 bg-white dark:border-strokedark dark:bg-boxdark dark:text-gray-200 !border-b !border-t-0 !border-r !border-l absolute w-full z-[999999999]"},Wn={class:"p-1"},Yn=e.createElementVNode("label",{for:"default-search",class:"mb-2 text-sm font-medium text-gray-900 sr-only dark:text-white"},"Search",-1),Xn={class:"relative"},Jn=e.createElementVNode("div",{class:"absolute inset-y-0 flex items-center pointer-events-none start-0 ps-3"},[e.createElementVNode("svg",{class:"w-4 h-4 text-gray-500 dark:text-gray-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m19 19-4-4m0-7A7 7 0 1 1 1 8a7 7 0 0 1 14 0Z"})])],-1),Qn=["id"],ea={class:"overflow-y-auto max-h-64"},ta=["onClick","onMousedown","id"],ra={class:"flex items-center py-2 pl-10 pr-4"},oa={key:0,class:"absolute flex items-center flex-shrink-0 w-4 h-4 text-green-500 left-2 dark:text-green-400","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 12"},na=[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M1 5.917 5.724 10.5 15 1.5"},null,-1)],aa={class:"block mt-1 text-sm font-normal leading-5 text-red-500"},la={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},sa={__name:"GlDropdown",props:{modelValue:{type:[String,Number],default:""},defaultValue:{type:[String,Number],default:""},field_name:{type:String,default:""},is_required:{type:Boolean,default:!1},has_cancel:{type:Boolean,default:!0},label_name:{type:String,default:""},options:{type:Array,required:!0,default:()=>[],note:"Options of dropdown. An array of options with id and name"},placeholder:{type:String,required:!1,default:"Please select an option",note:"Placeholder of dropdown"},maxItem:{type:Number,required:!1,default:1e4,note:"Max items showing"},show:{type:Boolean,default:!1},error_message:{type:String,default:""},description:{type:String,default:""}},emits:["update:modelValue","selected","selectionChanged"],setup(t,{emit:r}){const o=t,a=r,l=e.ref(null),n=e.ref({}),i=e.ref(0),s=e.ref(!1),d=e.ref(""),c=e.ref("");e.onMounted(()=>{c.value=S(),o.show||(document.body.addEventListener("click",f=>{A(f)}),document.addEventListener("keypress",f=>{f.key==="Enter"&&f.target.form&&f.preventDefault()}))});const m=e.computed(()=>te()),h=e.computed(()=>re()),b=e.computed(()=>{const f=[],x=new RegExp(d.value,"ig");for(const E of m.value){const $=String(E.name);(d.value.length<1||$.match(x))&&f.length<o.maxItem&&f.push(E)}return f});function _(f){if(["ArrowLeft","ArrowUp","ArrowRight","ArrowDown","Enter"].includes(f.key)){if(["ArrowUp","ArrowDown"].includes(f.key)&&f.preventDefault(),f.key==="ArrowDown"&&o.posts==="")return;ee(f.key)}}function S(){let f=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(E){const $=(f+Math.random()*16)%16|0;return f=Math.floor(f/16),(E==="x"?$:$&3|8).toString(16)})}function j(f){return f!==null&&typeof f=="object"&&Object.keys(f).length>0}function A(f){f.target.id!=o.field_name+"search"+c.value&&f.target.id!=o.field_name&&!f.target.classList.contains("showOptions")&&(z(),i.value=0)}function M(f){const x=`${f}${c.value}`,E=document.getElementById(x);E&&E.scrollIntoView()}function Q(f){const x=`${f}${c.value}`,E=document.getElementById(x);E&&E.click()}function ee(f){f==="ArrowDown"&&i.value<b.value.length&&(i.value++,M(i.value)),f==="ArrowUp"&&i.value>1&&(i.value--,M(i.value)),f==="Enter"&&Q(i.value)}function te(){return o.options.map((f,x)=>typeof f=="object"?f:{id:f,name:f})}function re(){if(j(n.value))return typeof n.value=="object"?m.value.find(f=>String(f.id)===String(n.value.id))||{}:m.value.find(f=>String(f.id)===String(n.value))||{};if(o.modelValue)return typeof o.modelValue=="object"?m.value.find(f=>String(f.id)===String(o.modelValue.id))||{}:m.value.find(f=>String(f.id)===String(o.modelValue))||{}}function L(f){n.value=f,s.value=!1,a("update:modelValue",n.value.id),a("selected",n.value),a("selectionChanged",n.value)}function I(){o.show||(d.value="",s.value=!0,e.nextTick(()=>{var f=document.getElementById(`${o.field_name}search${c.value}`);f&&f.focus()}))}function oe(){o.show||(n.value={},d.value="",a("update:modelValue",""),I())}function z(){n.value.id||(n.value={},d.value=""),a("selected",n.value),s.value=!1}return e.watch(d,()=>{b.value.length===0&&(n.value={})}),e.watch(n,f=>{j(f)&&a("update:modelValue",f.id)}),(f,x)=>{var E,$,g;return e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",zn,e.toDisplayString(t.label_name),1),e.createElementVNode("p",Gn,[e.createElementVNode("span",Fn,e.toDisplayString((E=h.value)==null?void 0:E.name),1)]),Un],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("input",{type:"hidden",name:t.field_name,id:t.field_name,value:($=h.value)==null?void 0:$.id},null,8,Rn),t.options?(e.openBlock(),e.createElementBlock("div",qn,[t.label_name?(e.openBlock(),e.createElementBlock("label",{key:0,class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required})},e.toDisplayString(t.label_name),3)):e.createCommentVNode("",!0),e.createElementVNode("div",Hn,[e.createElementVNode("div",Zn,[e.createElementVNode("input",{class:e.normalizeClass([{"gl-input-form":t.error_message=="","gl-input-form-invalid":t.error_message!==""},"pl-8 pr-2 showOptions"]),ref:t.field_name,onClick:x[0]||(x[0]=u=>I()),value:(g=h.value)==null?void 0:g.name,placeholder:t.placeholder,autocomplete:"off",readonly:""},null,10,Kn),e.withDirectives(e.createElementVNode("i",{onClick:x[1]||(x[1]=e.withModifiers(u=>oe(),["stop"])),class:"absolute text-gray-500 cursor-pointer fas fa-times right-7 hover:text-gray-700 dark:hover:text-gray-800",style:{top:"13px"}},null,512),[[e.vShow,j(h.value)&&t.has_cancel]]),e.createElementVNode("i",{onClick:x[2]||(x[2]=u=>!s.value&&I()),class:e.normalizeClass([s.value?"fa-angle-up":"fa-angle-down","absolute text-xl text-gray-500 cursor-pointer fas right-2 hover:text-gray-700 dark:hover:text-gray-800 showOptions"]),style:{top:"11px"}},null,2)]),e.withDirectives(e.createElementVNode("div",vn,[e.createElementVNode("div",Wn,[Yn,e.createElementVNode("div",Xn,[Jn,e.withDirectives(e.createElementVNode("input",{type:"search","onUpdate:modelValue":x[3]||(x[3]=u=>d.value=u),ref:l.value,id:`${t.field_name}search${c.value}`,onKeydown:_,onBlur:x[4]||(x[4]=u=>z()),autocomplete:"off",class:"block w-full p-2 text-sm text-gray-900 border rounded-lg outline-none border-frontend ps-10 bg-gray-50 focus:border-frontend dark:bg-gray-700 dark:border-frontenddark dark:placeholder-frontenddark dark:text-white dark:focus:border-frontenddark",placeholder:"Search ..."},null,40,Qn),[[e.vModelText,d.value]])])]),e.createElementVNode("div",ea,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(u,y)=>{var w;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["relative px-2 py-2 text-xs leading-4 text-gray-700 no-underline cursor-pointer dark:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white",y+1==i.value?"bg-gray-100 dark:bg-gray-600":""]),onClick:R=>L(u),onMousedown:R=>L(u),key:y,id:`${y+1}${c.value}`},[e.createElementVNode("div",ra,[((w=h.value)==null?void 0:w.id)===u.id?(e.openBlock(),e.createElementBlock("svg",oa,na)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.name||u.id||"-"),1)])],42,ta)}),128))])],512),[[e.vShow,s.value]])])])):e.createCommentVNode("",!0),e.createElementVNode("span",aa,e.toDisplayString(t.error_message),1),e.createElementVNode("small",la,e.toDisplayString(t.description),1)],2))],64)}}},ia={class:"font-bold ptext-lg dark:text-white"},da=["id"],ca=e.createElementVNode("hr",{class:"!opacity-100 bg-gray-200 border-0 dark:bg-gray-700"},null,-1),ma=["for"],ga=["required","name","id","type","placeholder"],fa={class:"gl-span-form-error"},ha={class:"block mt-1 text-sm font-normal leading-5 text-gray-500"},ua={__name:"GlTextarea",props:{is_required:{type:Boolean,default:!1},show:{type:Boolean,default:!1},error_message:{type:String,default:""},model_value:{type:[String,Number],default:""},modelValue:{type:[String,Number],default:""},type:{type:String,default:"text"},field_name:{type:String,default:""},label_name:{type:String,default:""},description:{type:String,default:""},placeholder:{type:String,default:""}},emits:["update:modelValue","keydown"],setup(t,{expose:r,emit:o}){const a=t,l=o,n=e.ref(null);e.onMounted(()=>{n.value!==null&&n.value.hasAttribute("autofocus")&&n.value.focus()});const i=e.computed({get(){return a.modelValue},set(s){l("update:modelValue",s)}});return r({focus:()=>n.value.focus()}),(s,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[t.show?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.field_name)},[e.createElementVNode("h3",ia,e.toDisplayString(t.label_name),1),e.createElementVNode("p",{id:t.field_name,class:"mb-4 text-base text-gray-900 input_tr_show dark:text-white"},e.toDisplayString(t.model_value),9,da),ca],2)):e.createCommentVNode("",!0),t.show?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["mb-4",t.field_name])},[e.createElementVNode("label",{class:e.normalizeClass({"gl-label-form":t.error_message=="","gl-label-form-invalid":t.error_message!=="",required:t.is_required}),for:t.field_name},e.toDisplayString(t.label_name),11,ma),e.withDirectives(e.createElementVNode("textarea",{required:t.is_required,name:t.field_name,id:t.field_name,class:e.normalizeClass({" gl-textarea-form mt-4 ":t.error_message==""," gl-textarea-form-invalid mt-4 ":t.error_message!==""}),type:t.type,"onUpdate:modelValue":d[0]||(d[0]=c=>i.value=c),onKeydown:d[1]||(d[1]=c=>s.$emit("keydown",c)),ref_key:"input",ref:n,rows:"4",placeholder:t.placeholder},null,42,ga),[[e.vModelText,i.value]]),e.createElementVNode("span",fa,e.toDisplayString(t.error_message),1),e.createElementVNode("small",ha,e.toDisplayString(t.description),1)],2))],64))}},pa={compatConfig:{MODE:3},inheritAttrs:!1,emits:["pagination-change-page"],components:{RenderlessPagination:{emits:["pagination-change-page"],props:{data:{type:Object,default:()=>{}},limit:{type:Number,default:0}},computed:{isApiResource(){return!!this.data.meta},currentPage(){return this.isApiResource?this.data.meta.current_page:this.data.current_page},firstPageUrl(){return this.isApiResource?this.data.links.first:null},from(){return this.isApiResource?this.data.meta.from:this.data.from},lastPage(){return this.isApiResource?this.data.meta.last_page:this.data.last_page},lastPageUrl(){return this.isApiResource?this.data.links.last:null},nextPageUrl(){return this.isApiResource?this.data.links.next:this.data.next_page_url},perPage(){return this.isApiResource?this.data.meta.per_page:this.data.per_page},prevPageUrl(){return this.isApiResource?this.data.links.prev:this.data.prev_page_url},to(){return this.isApiResource?this.data.meta.to:this.data.to},total(){return this.isApiResource?this.data.meta.total:this.data.total},pageRange(){if(this.limit===-1)return 0;if(this.limit===0)return this.lastPage;for(var t=this.currentPage,r=this.lastPage,o=this.limit,a=t-o,l=t+o+1,n=[],i=[],s,d=1;d<=r;d++)(d===1||d===r||d>=a&&d<l)&&n.push(d);return n.forEach(function(c){s&&(c-s===2?i.push(s+1):c-s!==1&&i.push("...")),i.push(c),s=c}),i}},methods:{previousPage(){this.selectPage(this.currentPage-1)},nextPage(){this.selectPage(this.currentPage+1)},selectPage(t){t!=="..."&&this.$emit("pagination-change-page",t)}},render(){return this.$slots.default({data:this.data,limit:this.limit,computed:{isApiResource:this.isApiResource,currentPage:this.currentPage,firstPageUrl:this.firstPageUrl,from:this.from,lastPage:this.lastPage,lastPageUrl:this.lastPageUrl,nextPageUrl:this.nextPageUrl,perPage:this.perPage,prevPageUrl:this.prevPageUrl,to:this.to,total:this.total,pageRange:this.pageRange},prevButtonEvents:{click:t=>{t.preventDefault(),this.previousPage()}},nextButtonEvents:{click:t=>{t.preventDefault(),this.nextPage()}},pageButtonEvents:t=>({click:r=>{r.preventDefault(),this.selectPage(t)}})})}}},props:{data:{type:Object,default:()=>{}},limit:{type:Number,default:0},showDisabled:{type:Boolean,default:!1},size:{type:String,default:"default",validator:t=>["small","default","large"].indexOf(t)!==-1},align:{type:String,default:"left",validator:t=>["left","center","right"].indexOf(t)!==-1}},methods:{onPaginationChangePage(t){this.$emit("pagination-change-page",t)}},mounted(){}},ya={class:"flex flex-col items-center"},ba={key:0,class:"text-sm text-gray-700 dark:text-gray-400"},_a={class:"font-semibold text-gray-900 dark:text-white"},ka={class:"font-semibold text-gray-900 dark:text-white"},xa={class:"font-semibold text-gray-900 dark:text-white"},wa=["tabindex"],Ea=e.createElementVNode("span",{class:"sr-only"},"Previous",-1),Na=e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 1 1 5l4 4"})],-1),Va=["aria-current"],Ba=["tabindex"],Ca=e.createElementVNode("span",{class:"sr-only"},"Next",-1),$a=e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m1 9 4-4-4-4"})],-1);function Sa(t,r,o,a,l,n){const i=e.resolveComponent("RenderlessPagination");return e.openBlock(),e.createBlock(i,{data:o.data,limit:o.limit,onPaginationChangePage:n.onPaginationChangePage},{default:e.withCtx(s=>[e.createElementVNode("div",ya,[s.computed.total>s.computed.perPage?(e.openBlock(),e.createElementBlock("span",ba,[e.createTextVNode(" Showing "),e.createElementVNode("span",_a,e.toDisplayString(s.computed.from),1),e.createTextVNode(" to "),e.createElementVNode("span",ka,e.toDisplayString(s.computed.to),1),e.createTextVNode(" of "),e.createElementVNode("span",xa,e.toDisplayString(s.computed.total),1),e.createTextVNode(" Entries ")])):e.createCommentVNode("",!0),s.computed.total>s.computed.perPage?(e.openBlock(),e.createElementBlock("ul",e.mergeProps({key:1},t.$attrs,{class:["flex items-center h-8 -space-x-px text-sm",{"pagination-sm":o.size=="small","pagination-lg":o.size=="large","justify-content-center":o.align=="center","justify-content-end":o.align=="right"}]}),[s.computed.prevPageUrl||o.showDisabled?(e.openBlock(),e.createElementBlock("li",{key:0,class:e.normalizeClass(["flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 ms-0 border-e-0 rounded-s-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white",{disabled:!s.computed.prevPageUrl}])},[e.createElementVNode("a",e.mergeProps({class:"page-link",href:"#","aria-label":"Previous",tabindex:!s.computed.prevPageUrl&&-1},e.toHandlers(s.prevButtonEvents,!0)),[e.renderSlot(t.$slots,"prev-nav",{},()=>[Ea,Na])],16,wa)],2)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.computed.pageRange,(d,c)=>(e.openBlock(),e.createElementBlock("li",{class:e.normalizeClass(["",{active:d==s.computed.currentPage}]),key:c},[e.createElementVNode("a",e.mergeProps({class:"",href:"#"},e.toHandlers(s.pageButtonEvents(d),!0),{"aria-current":d==s.computed.currentPage?"page":null,class:d==s.computed.currentPage?"z-10 flex items-center justify-center px-3 h-8 leading-tight text-blue-600 border border-blue-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white":"flex items-center justify-center px-3 h-8 leading-tight text-gray-500 bg-white border border-gray-300 hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"}),e.toDisplayString(d),17,Va)],2))),128)),s.computed.nextPageUrl||o.showDisabled?(e.openBlock(),e.createElementBlock("li",{key:1,class:e.normalizeClass(["flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 rounded-e-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white",{disabled:!s.computed.nextPageUrl}])},[e.createElementVNode("a",e.mergeProps({class:"",href:"#","aria-label":"Next",tabindex:!s.computed.nextPageUrl&&-1},e.toHandlers(s.nextButtonEvents,!0)),[e.renderSlot(t.$slots,"next-nav",{},()=>[Ca,$a])],16,Ba)],2)):e.createCommentVNode("",!0)],16)):e.createCommentVNode("",!0)])]),_:3},8,["data","limit","onPaginationChangePage"])}const Ve=k(pa,[["render",Sa]]),Da={components:{TailwindPagination:Ve},props:{data:Array,columns:Array,get_item_url:String,xprops:Object,refreshData:Boolean},data(){return{isLoading:!1,isMounted:!1,limit:5,showDisabled:!1,size:"default",align:"left",search:"",isDropdownOpen:!1,itemLists:[],tableData:[],sortField:this.columns[0].field_name,sortOrder:"desc",pageOptions:[5,10,20,50],perPage:5,page:1}},emits:["editAction"],computed:{filteredData(){const t=this.search.toLowerCase();return this.sortData(this.data).filter(o=>Object.values(o).some(a=>a.toString().toLowerCase().includes(t)))}},methods:{editAction(t){this.$emit("editAction",t)},forDynCompIs(t){return typeof t=="object"?t:null},GetItemLists(t=1){this.isLoading=!0,this.page=t;const r={sort:this.sortField,order:this.sortOrder,s:this.search,limit:this.perPage,page:this.page};axios.get(this.xprops.route_get_data,{params:r}).then(o=>{this.itemLists=o.data,this.isLoading=!1}).catch(o=>{console.error(o),this.isLoading=!1})},updateSortColumn(t,r){r&&(t===this.sortField?this.sortOrder=this.sortOrder==="asc"?"desc":"asc":(this.sortField=t,this.sortOrder="asc"),this.GetItemLists(this.page))},handleSearch(){this.sortField=this.columns[0].field_name,this.sortOrder="asc",this.page=1,this.GetItemLists(this.page)}},mounted(){this.GetItemLists(),this.isMounted=!0},watch:{searchFilter(){this.filteredOptions.length===0?this.selected={}:this.selected=this.filteredOptions[0]},perPage(t){this.page=1,this.perPage=t,this.GetItemLists(this.page)},refreshData(t,r){this.isMounted&&t!==r&&this.GetItemLists()}}},Ta={class:"p-2"},Oa={class:"flex flex-col flex-wrap pb-4 space-y-4 xl:flex-row xl:items-center xl:justify-between flex-column sm:space-y-0"},Pa={class:"flex items-center gap-2"},ja=e.createElementVNode("span",{class:"font-medium"}," Show ",-1),Aa={style:{"margin-top":"9px"}},Ma=e.createElementVNode("span",{class:"font-medium"}," Entries ",-1),La=e.createElementVNode("label",{for:"table-search",class:"sr-only"},"Search",-1),Ia={class:"relative"},za=e.createElementVNode("div",{class:"absolute inset-y-0 left-0 flex items-center pointer-events-none rtl:inset-r-0 rtl:right-0 ps-3"},[e.createElementVNode("svg",{class:"w-5 h-5 text-gray-500 dark:text-gray-400","aria-hidden":"true",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z","clip-rule":"evenodd"})])],-1),Ga={class:"overflow-auto rounded-lg dark:text-gray-400 dark:bg-gray-800"},Fa={class:"w-full h-full max-w-full overflow-hidden bg-white border-separate xl:overflow-auto lg:border-collapse border-spacing-y-3 lg:border-spacing-y-0 dark:border-strokedark dark:bg-boxdark"},Ua={class:"hidden text-sm font-normal text-center text-gray-500 lg:table-header-group dark:border-strokedark bg-gray-50 dark:bg-gray-700 dark:text-gray-400"},Ra=["onClick"],qa={key:0,class:"ml-2"},Ha={key:0,class:"fa fa-arrow-up"},Za={key:1,class:"fa fa-arrow-down"},Ka={key:0},va=["colspan"],Wa=[e.createElementVNode("div",{role:"status",class:"p-4 space-y-4 border border-gray-200 divide-y divide-gray-200 rounded shadow animate-pulse dark:divide-gray-700 md:p-6 dark:border-gray-700"},[e.createElementVNode("div",{class:"flex items-center justify-between"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("div",{class:"flex items-center justify-between pt-4"},[e.createElementVNode("div",null,[e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-600 w-24 mb-3"}),e.createElementVNode("div",{class:"w-32 h-2 bg-gray-200 rounded-full dark:bg-gray-700"})]),e.createElementVNode("div",{class:"h-3 bg-gray-300 rounded-full dark:bg-gray-700 w-12"})]),e.createElementVNode("span",{class:"sr-only"},"Loading...")],-1)],Ya=["data-label"],Xa={class:"overflow-auto max-h-40"},Ja={class:"flex items-center justify-between px-4 py-3 bg-white border-gray-200 sm:px-6 dark:text-gray-400 dark:bg-gray-800"};function Qa(t,r,o,a,l,n){const i=e.resolveComponent("dropdown"),s=e.resolveComponent("TailwindPagination");return e.openBlock(),e.createElementBlock("div",Ta,[e.createElementVNode("div",Oa,[e.createElementVNode("div",Pa,[ja,e.createElementVNode("div",Aa,[e.createVNode(i,{has_cancel:!1,options:l.pageOptions,modelValue:l.perPage,"onUpdate:modelValue":r[0]||(r[0]=d=>l.perPage=d),is_required:!1,field_name:"perPage",label_name:"",default_value:5,show:!1,placeholder:"Please select an option"},null,8,["options","modelValue"])]),Ma]),La,e.createElementVNode("div",Ia,[za,e.withDirectives(e.createElementVNode("input",{type:"text","onUpdate:modelValue":r[1]||(r[1]=d=>l.search=d),onInput:r[2]||(r[2]=d=>n.handleSearch()),class:"block w-full p-2 text-sm text-gray-900 border border-gray-300 rounded-lg ps-10 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500",placeholder:"Search ..."},null,544),[[e.vModelText,l.search]])])]),e.createElementVNode("div",Ga,[e.createElementVNode("table",Fa,[e.createElementVNode("thead",Ua,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(d,c)=>(e.openBlock(),e.createElementBlock("th",{key:c,onClick:m=>n.updateSortColumn(d.field_name,d.sortable),class:"w-full px-4 py-2 lg:w-2/12"},[e.createTextVNode(e.toDisplayString(d.field_label)+" ",1),l.sortField===d.field_name?(e.openBlock(),e.createElementBlock("span",qa,[l.sortOrder==="asc"?(e.openBlock(),e.createElementBlock("i",Ha)):(e.openBlock(),e.createElementBlock("i",Za))])):e.createCommentVNode("",!0)],8,Ra))),128))])]),e.createElementVNode("tbody",null,[l.isLoading?(e.openBlock(),e.createElementBlock("tr",Ka,[e.createElementVNode("td",{colspan:o.columns.length},Wa,8,va)])):e.createCommentVNode("",!0),l.isLoading?e.createCommentVNode("",!0):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(l.itemLists.data,(d,c)=>(e.openBlock(),e.createElementBlock("tr",{key:c,class:"bg-white dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600 hover:dark:text-gray-200 text-gray-500"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(m,h)=>(e.openBlock(),e.createElementBlock("td",{key:h,"data-label":m.field_label,class:"text-pretty before:content-[attr(data-label)] before:font-bold lg:before:content-none flex md:flex-row flex-col justify-between gap-2 lg:table-cell py-4 px-5 lg:py-2.5 lg:px-4 border dark:border-gray-700"},[e.createElementVNode("div",Xa,[m.tdComp?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.forDynCompIs(m.tdComp)),{key:0,row:d,field:m.field_name,xprops:o.xprops,tdProps:m.tdProps,onDeleteAction:r[3]||(r[3]=b=>n.GetItemLists()),onEditAction:b=>n.editAction(d)},null,40,["row","field","xprops","tdProps","onEditAction"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(d[m.field_name]),1)],64))])],8,Ya))),128))]))),128))])])]),e.createElementVNode("div",Ja,[e.createVNode(s,{class:"mt-3 mb-0",data:l.itemLists,limit:l.limit,size:l.size,align:l.align,onPaginationChangePage:n.GetItemLists},null,8,["data","limit","size","align","onPaginationChangePage"])])])}const el=k(Da,[["render",Qa]]),tl={components:{},props:{data:Array,columns:Array},data(){return{showNoOfEntries:[1,2,3,10,20,30,40],search:"",sortKey:"",sortOrder:1,currentPage:1,itemsPerPage:10,jumpToPage:"",maxDisplayedPages:10}},computed:{filteredData(){const t=this.search.toLowerCase();return this.sortData(this.data).filter(o=>Object.values(o).some(a=>a!=null&&a.toString().toLowerCase().includes(t)))},totalPages(){return Math.ceil(this.filteredData.length/this.itemsPerPage)},paginatedData(){const t=(this.currentPage-1)*this.itemsPerPage,r=t+this.itemsPerPage;return this.filteredData.slice(t,r)},displayedPageNumbers(){let t=Math.max(this.currentPage-Math.floor(this.maxDisplayedPages/2),1),r=t+this.maxDisplayedPages-1;return r>this.totalPages&&(r=this.totalPages,t=Math.max(r-this.maxDisplayedPages+1,1)),Array.from({length:r-t+1},(o,a)=>t+a)},firstItemIndex(){return this.itemsPerPage*(this.currentPage-1)+1},lastItemIndex(){const t=this.itemsPerPage*this.currentPage;return t>this.filteredData.length?this.filteredData.length:t}},methods:{handleItemsPerPageChange(t){this.itemsPerPage=t},goToPage(t){t>=1&&t<=this.totalPages&&(this.currentPage=t)},sort(t){t===this.sortKey?this.sortOrder*=-1:(this.sortKey=t,this.sortOrder=1)},sortData(t){return this.sortKey?t.slice().sort((r,o)=>(r[this.sortKey]<o[this.sortKey]?-1:1)*this.sortOrder):t},previousPage(){this.currentPage>1&&this.currentPage--},nextPage(){this.currentPage<this.totalPages&&this.currentPage++},firstPage(){this.currentPage=1},lastPage(){this.currentPage=this.totalPages},goToPage(t){t>=1&&t<=this.totalPages&&(this.currentPage=t)}}},rl={class:"p-2"},ol={class:"flex flex-wrap pb-4 space-y-4 md:items-center md:justify-between flex-column sm:flex-row sm:space-y-0"},nl={class:"flex items-center gap-2"},al=e.createElementVNode("span",{class:"font-medium"}," Show ",-1),ll={style:{"margin-top":"9px"}},sl=e.createElementVNode("span",{class:"font-medium"}," Entries ",-1),il=e.createElementVNode("label",{for:"table-search",class:"sr-only"},"Search",-1),dl={class:"relative"},cl=e.createElementVNode("div",{class:"absolute inset-y-0 left-0 flex items-center pointer-events-none rtl:inset-r-0 rtl:right-0 ps-3"},[e.createElementVNode("svg",{class:"w-5 h-5 text-gray-500 dark:text-gray-400","aria-hidden":"true",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z","clip-rule":"evenodd"})])],-1),ml={class:"overflow-auto rounded-lg dark:text-gray-400 dark:bg-gray-800"},gl={class:"w-full h-full max-w-full overflow-hidden bg-white border-separate xl:overflow-auto lg:border-collapse border-spacing-y-3 lg:border-spacing-y-0 dark:border-strokedark dark:bg-boxdark"},fl={class:"hidden text-sm font-normal text-center text-gray-700 lg:table-header-group dark:border-strokedark bg-gray-50 dark:bg-gray-700 dark:text-gray-400"},hl=["onClick"],ul={key:0,class:"ml-2"},pl={key:0,class:"fa fa-arrow-up"},yl={key:1,class:"fa fa-arrow-down"},bl=["data-label"],_l=["innerHTML"],kl={key:0,class:"flex items-center justify-between px-4 py-3 bg-white border-gray-200 sm:px-6 dark:text-gray-400 dark:bg-gray-800"},xl={class:"flex justify-between flex-1 sm:hidden"},wl=["disabled"],El=["disabled"],Nl={class:"hidden sm:flex sm:flex-1 sm:items-center sm:justify-between"},Vl={class:"text-sm text-gray-700 dark:text-gray-400"},Bl={class:"font-medium"},Cl={class:"font-medium"},$l={class:"font-medium"},Sl={"aria-label":"Page navigation"},Dl={class:"flex items-center h-8 -space-x-px text-sm"},Tl=["disabled"],Ol=[e.createElementVNode("span",{class:"sr-only"},"Previous",-1),e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M5 1 1 5l4 4"})],-1)],Pl=["onClick"],jl=["onClick"],Al=["disabled"],Ml=[e.createElementVNode("span",{class:"sr-only"},"Next",-1),e.createElementVNode("svg",{class:"w-2.5 h-2.5 rtl:rotate-180","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 6 10"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m1 9 4-4-4-4"})],-1)];function Ll(t,r,o,a,l,n){const i=e.resolveComponent("dropdown");return e.openBlock(),e.createElementBlock("div",rl,[e.createElementVNode("div",ol,[e.createElementVNode("div",nl,[al,e.createElementVNode("div",ll,[e.createVNode(i,{has_cancel:!1,options:l.showNoOfEntries,modelValue:l.itemsPerPage,"onUpdate:modelValue":r[0]||(r[0]=s=>l.itemsPerPage=s),is_required:!1,field_name:"NoOfEntries",label_name:"",default_value:10,show:!1,placeholder:"Please select an option"},null,8,["options","modelValue"])]),sl]),il,e.createElementVNode("div",dl,[cl,e.withDirectives(e.createElementVNode("input",{type:"text","onUpdate:modelValue":r[1]||(r[1]=s=>l.search=s),class:"block p-2 text-sm text-gray-900 border border-gray-300 rounded-lg ps-10 w-80 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500",placeholder:"Search ..."},null,512),[[e.vModelText,l.search]])])]),e.createElementVNode("div",ml,[e.createElementVNode("table",gl,[e.createElementVNode("thead",fl,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(s,d)=>(e.openBlock(),e.createElementBlock("th",{key:d,onClick:c=>n.sort(s),class:"w-full px-4 py-2 lg:w-2/12"},[e.createTextVNode(e.toDisplayString(s)+" ",1),l.sortKey===s?(e.openBlock(),e.createElementBlock("span",ul,[l.sortOrder==="asc"?(e.openBlock(),e.createElementBlock("i",pl)):(e.openBlock(),e.createElementBlock("i",yl))])):e.createCommentVNode("",!0)],8,hl))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.paginatedData,(s,d)=>(e.openBlock(),e.createElementBlock("tr",{key:d,class:"bg-white dark:bg-gray-800 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-600 hover:dark:text-gray-200 text-gray-500"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.columns,(c,m)=>(e.openBlock(),e.createElementBlock("td",{key:m,"data-label":c,class:"text-pretty before:content-[attr(data-label)] before:font-bold lg:before:content-none flex md:flex-row flex-col justify-between gap-2 lg:table-cell py-4 px-5 lg:py-2.5 lg:px-4 border dark:border-gray-700"},[e.createElementVNode("p",{class:"text-pretty",innerHTML:s[m]},null,8,_l)],8,bl))),128))]))),128))])])]),n.paginatedData.length>0?(e.openBlock(),e.createElementBlock("div",kl,[e.createElementVNode("div",xl,[e.createElementVNode("a",{href:"#",onClick:r[2]||(r[2]=(...s)=>n.previousPage&&n.previousPage(...s)),disabled:l.currentPage===1,class:"relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50"},"Previous",8,wl),e.createElementVNode("a",{href:"#",onClick:r[3]||(r[3]=(...s)=>n.nextPage&&n.nextPage(...s)),disabled:l.currentPage===n.totalPages,class:"relative inline-flex items-center px-4 py-2 ml-3 text-sm font-medium text-gray-700 bg-white border border-gray-300 rounded-md hover:bg-gray-50"},"Next",8,El)]),e.createElementVNode("div",Nl,[e.createElementVNode("div",null,[e.createElementVNode("p",Vl,[e.createTextVNode(" Showing "),e.createElementVNode("span",Bl,e.toDisplayString(n.firstItemIndex),1),e.createTextVNode(" to "),e.createElementVNode("span",Cl,e.toDisplayString(n.lastItemIndex),1),e.createTextVNode(" of "),e.createElementVNode("span",$l,e.toDisplayString(n.filteredData.length),1),e.createTextVNode(" entries ")])]),e.createElementVNode("div",null,[e.createElementVNode("nav",Sl,[e.createElementVNode("ul",Dl,[e.createElementVNode("li",null,[e.createElementVNode("a",{href:"#",onClick:r[4]||(r[4]=(...s)=>n.previousPage&&n.previousPage(...s)),disabled:l.currentPage===1,class:"flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 ms-0 border-e-0 rounded-s-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"},Ol,8,Tl)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.displayedPageNumbers,s=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:s},[e.createElementVNode("li",null,[l.currentPage!==s?(e.openBlock(),e.createElementBlock("a",{key:0,href:"#",onClick:d=>n.goToPage(s),class:"flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"},e.toDisplayString(s),9,Pl)):e.createCommentVNode("",!0)]),e.createElementVNode("li",null,[l.currentPage===s?(e.openBlock(),e.createElementBlock("a",{key:0,href:"#",onClick:d=>n.goToPage(s),"aria-current":"page",class:"z-10 flex items-center justify-center h-8 px-3 leading-tight text-blue-600 border border-blue-300 bg-blue-50 hover:bg-blue-100 hover:text-blue-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white"},e.toDisplayString(s),9,jl)):e.createCommentVNode("",!0)])],64))),128)),e.createElementVNode("li",null,[e.createElementVNode("a",{href:"#",onClick:r[5]||(r[5]=(...s)=>n.nextPage&&n.nextPage(...s)),disabled:l.currentPage===n.totalPages,class:"flex items-center justify-center h-8 px-3 leading-tight text-gray-500 bg-white border border-gray-300 rounded-e-lg hover:bg-gray-100 hover:text-gray-700 dark:bg-gray-800 dark:border-gray-700 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white"},Ml,8,Al)])])])])])])):e.createCommentVNode("",!0)])}const Il=k(tl,[["render",Ll]]),zl={class:"flex items-center p-4 text-gray-500 bg-white rounded-lg shadow dark:bg-gray-800 dark:text-gray-400",role:"alert"},Gl={key:0,class:"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-green-500 bg-green-100 rounded-lg dark:bg-green-800 dark:text-green-200"},Fl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5Zm3.707 8.207-4 4a1 1 0 0 1-1.414 0l-2-2a1 1 0 0 1 1.414-1.414L9 10.586l3.293-3.293a1 1 0 0 1 1.414 1.414Z"})],-1),e.createElementVNode("span",{class:"sr-only"},"Check icon",-1)],Ul={key:1,class:"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-red-500 bg-red-100 rounded-lg dark:bg-red-800 dark:text-red-200"},Rl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5Zm3.707 11.793a1 1 0 1 1-1.414 1.414L10 11.414l-2.293 2.293a1 1 0 0 1-1.414-1.414L8.586 10 6.293 7.707a1 1 0 0 1 1.414-1.414L10 8.586l2.293-2.293a1 1 0 0 1 1.414 1.414L11.414 10l2.293 2.293Z"})],-1),e.createElementVNode("span",{class:"sr-only"},"Error icon",-1)],ql={key:2,class:"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-orange-500 bg-orange-100 rounded-lg dark:bg-orange-700 dark:text-orange-200"},Hl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 20 20"},[e.createElementVNode("path",{d:"M10 .5a9.5 9.5 0 1 0 9.5 9.5A9.51 9.51 0 0 0 10 .5ZM10 15a1 1 0 1 1 0-2 1 1 0 0 1 0 2Zm1-4a1 1 0 0 1-2 0V6a1 1 0 0 1 2 0v5Z"})],-1),e.createElementVNode("span",{class:"sr-only"},"Warning icon",-1)],Zl={class:"ml-3 text-sm font-normal"},Kl=[e.createElementVNode("span",{class:"sr-only"},"Close",-1),e.createElementVNode("svg",{"aria-hidden":"true",class:"w-5 h-5",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)],vl={__name:"ToastListItem",props:{message:String,duration:{type:Number,default:2e3},type:{type:String,default:"success"}},emits:["remove"],setup(t,{emit:r}){const o=t;e.onMounted(()=>{setTimeout(()=>a("remove"),o.duration)});const a=r;return(l,n)=>(e.openBlock(),e.createElementBlock("div",zl,[o.type==="success"?(e.openBlock(),e.createElementBlock("div",Gl,Fl)):e.createCommentVNode("",!0),o.type==="error"?(e.openBlock(),e.createElementBlock("div",Ul,Rl)):e.createCommentVNode("",!0),o.type==="warning"?(e.openBlock(),e.createElementBlock("div",ql,Hl)):e.createCommentVNode("",!0),e.createElementVNode("div",Zl,e.toDisplayString(o.message),1),e.createElementVNode("button",{onClick:n[0]||(n[0]=i=>a("remove")),type:"button",class:"-mx-1.5 -my-1.5 ml-auto inline-flex h-8 w-8 rounded-lg bg-white p-1.5 text-gray-400 hover:bg-gray-100 hover:text-gray-900 focus:ring-2 focus:ring-gray-300 dark:bg-gray-800 dark:text-gray-500 dark:hover:bg-gray-700 dark:hover:text-white","data-dismiss-target":"#toast-default","aria-label":"Close"},Kl)]))}},X=e.reactive({items:[]}),J={state:X,methods:{add(t){X.items.unshift({key:Symbol(),message:t.message,type:t.type,duration:t.duration})},remove(t){X.items.splice(t,1)}}},Wl={__name:"GlToastList",setup(t){function r(o){J.methods.remove(o)}return(o,a)=>(e.openBlock(),e.createBlock(e.TransitionGroup,{tag:"div","enter-from-class":"translate-x-full opacity-0","enter-active-class":"duration-500","leave-active-class":"duration-500","leave-to-class":"translate-x-full opacity-0",class:"fixed z-50 w-full max-w-xs space-y-4 top-4 right-4"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(J).state.items,(l,n)=>(e.openBlock(),e.createBlock(vl,{key:l.key,message:l.message,type:l.type,duration:l.duration,onRemove:i=>r(n)},null,8,["message","type","duration","onRemove"]))),128))]),_:1}))}},Yl={key:0,class:"flex justify-center"},Xl=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 4 15"},[e.createElementVNode("path",{d:"M3.5 1.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 6.041a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 5.959a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z"})],-1)],Jl={class:"absolute right-0 z-10 mt-5 origin-top-right bg-white divide-y divide-gray-100 rounded-lg shadow w-44 dark:bg-gray-700 dark:divide-gray-600"},Ql={class:"py-2 text-sm text-gray-700 dark:text-gray-200","aria-labelledby":"dropdownDividerButton"},es={key:0},ts=["href"],rs=e.createElementVNode("i",{class:"mr-2 fa-solid fa-list-ul opacity-80"},null,-1),os={key:1},ns=e.createElementVNode("i",{class:"mr-2 fa-solid fa-trash-can opacity-80"},null,-1),as={__name:"DatatableAction",props:{field:{type:String,default:""},route_url:{type:String,default:""},row:{type:[Array,Object],default:[]},xprops:{type:Object,default:{}},tdProps:{type:Object,default:{}}},emits:["deleteAction"],setup(t,{emit:r}){const o=le(),a=t,l=e.ref(!1),n=e.ref(!1),i=()=>{l.value=!1},s=()=>{l.value=!0},d=()=>{n.value=!1},c=()=>{n.value=!0},m=r,h=()=>{axios.delete(`${a.xprops.route}/${a.row.id}`).then(()=>{d(),m("deleteAction"),o.commit("notification/SHOW_NOTIFICATION",{message:"Item deleted successfully.",type:"success",duration:5e3})}).catch(b=>{console.log(b)})};return(b,_)=>{const S=e.resolveDirective("click-outside");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(G,{isOpen:n.value,onConfirmDelete:h,onCancelDelete:d},null,8,["isOpen"]),t.row&&b.can(`edit_${t.xprops.permission} || delete_${t.xprops.permission}`)?e.withDirectives((e.openBlock(),e.createElementBlock("div",Yl,[e.createElementVNode("button",{onClick:s,class:"inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-white rounded-lg hover:bg-gray-100 focus:ring-4 focus:outline-none dark:text-white focus:ring-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-600",type:"button"},Xl),e.withDirectives(e.createElementVNode("div",Jl,[e.createElementVNode("ul",Ql,[b.can(`edit_${t.xprops.permission}`)?(e.openBlock(),e.createElementBlock("li",es,[e.createElementVNode("a",{href:t.xprops.route+"/"+t.row.id+"/edit",class:"block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"},[rs,e.createTextVNode(" Edit")],8,ts)])):e.createCommentVNode("",!0),b.can(`delete_${t.xprops.permission}`)?(e.openBlock(),e.createElementBlock("li",os,[e.createElementVNode("a",{href:"#",onClick:e.withModifiers(c,["prevent"]),class:"block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"},[ns,e.createTextVNode(" Remove")])])):e.createCommentVNode("",!0)])],512),[[e.vShow,l.value]])])),[[S,i]]):e.createCommentVNode("",!0)],64)}}},ls={key:0,class:"flex justify-center"},ss=[e.createElementVNode("svg",{class:"w-5 h-5","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 4 15"},[e.createElementVNode("path",{d:"M3.5 1.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 6.041a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Zm0 5.959a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0Z"})],-1)],is={class:"absolute right-0 z-10 mt-5 origin-top-right bg-white divide-y divide-gray-100 rounded-lg shadow w-44 dark:bg-gray-700 dark:divide-gray-600"},ds={class:"py-2 text-sm text-gray-700 dark:text-gray-200","aria-labelledby":"dropdownDividerButton"},cs={key:0},ms=e.createElementVNode("i",{class:"mr-2 fa-solid fa-trash-can opacity-80"},null,-1),gs={__name:"DatatableDeleteAction",props:{field:{type:String,default:""},route_url:{type:String,default:""},row:{type:[Array,Object],default:[]},xprops:{type:Object,default:{}},tdProps:{type:Object,default:{}}},emits:["deleteAction"],setup(t,{emit:r}){const o=le(),a=t,l=e.ref(!1),n=e.ref(!1),i=()=>{l.value=!1},s=()=>{l.value=!0},d=()=>{n.value=!1},c=()=>{n.value=!0},m=r,h=()=>{axios.delete(`${a.xprops.route}/${a.row.id}`).then(()=>{d(),m("deleteAction"),o.commit("notification/SHOW_NOTIFICATION",{message:"Item deleted successfully.",type:"success",duration:5e3})}).catch(b=>{console.log(b)})};return(b,_)=>{const S=e.resolveDirective("click-outside");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(G,{isOpen:n.value,onConfirmDelete:h,onCancelDelete:d},null,8,["isOpen"]),t.row&&b.can(`delete_${t.xprops.permission}`)?e.withDirectives((e.openBlock(),e.createElementBlock("div",ls,[e.createElementVNode("button",{onClick:s,class:"inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-white rounded-lg hover:bg-gray-100 focus:ring-4 focus:outline-none dark:text-white focus:ring-gray-50 dark:bg-gray-800 dark:hover:bg-gray-700 dark:focus:ring-gray-600",type:"button"},ss),e.withDirectives(e.createElementVNode("div",is,[e.createElementVNode("ul",ds,[b.can(`delete_${t.xprops.permission}`)?(e.openBlock(),e.createElementBlock("li",cs,[e.createElementVNode("a",{href:"#",onClick:e.withModifiers(c,["prevent"]),class:"block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white"},[ms,e.createTextVNode(" Remove")])])):e.createCommentVNode("",!0)])],512),[[e.vShow,l.value]])])),[[S,i]]):e.createCommentVNode("",!0)],64)}}},fs={props:["field","row"],computed:{isArray(){return Array.isArray(this.row)},isObject(){return typeof this.row=="object"},isString(){return typeof this.row=="string"}},mounted(){}},hs=["href","title"],us=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1),ps={key:1,class:"m-1 d-inline-block"},ys=["href","title"],bs=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1);function _s(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",null,[n.isArray?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(o.row,(i,s)=>(e.openBlock(),e.createElementBlock("div",{key:s,class:"m-1 d-inline-block"},[e.createElementVNode("a",{href:i,title:i,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[us,e.createTextVNode(" Download ")],8,hs)]))),128)):n.isString?(e.openBlock(),e.createElementBlock("div",ps,[e.createElementVNode("a",{href:o.row,title:o.row,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[bs,e.createTextVNode(" Download ")],8,ys)])):e.createCommentVNode("",!0)])}const ks=k(fs,[["render",_s]]),xs={props:["field","row"],computed:{isArray(){return Array.isArray(this.row[this.field])},isObject(){return typeof this.row[this.field]=="object"}}},ws=["href","title"],Es=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1),Ns={key:1,class:"m-1 d-inline-block"},Vs=["href","title"],Bs=e.createElementVNode("svg",{class:"w-3 h-3 text-white me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"fill-rule":"evenodd",d:"M13 11.15V4a1 1 0 1 0-2 0v7.15L8.78 8.374a1 1 0 1 0-1.56 1.25l4 5a1 1 0 0 0 1.56 0l4-5a1 1 0 1 0-1.56-1.25L13 11.15Z","clip-rule":"evenodd"}),e.createElementVNode("path",{"fill-rule":"evenodd",d:"M9.657 15.874 7.358 13H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2h-2.358l-2.3 2.874a3 3 0 0 1-4.685 0ZM17 16a1 1 0 1 0 0 2h.01a1 1 0 1 0 0-2H17Z","clip-rule":"evenodd"})],-1);function Cs(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",null,[n.isArray?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(o.row[o.field],i=>(e.openBlock(),e.createElementBlock("div",{key:i.id,class:"m-1 d-inline-block"},[e.createElementVNode("a",{href:i.url,title:i.name,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[Es,e.createTextVNode(" Download ")],8,ws)]))),128)):n.isObject?(e.openBlock(),e.createElementBlock("div",Ns,[e.createElementVNode("a",{href:o.row[o.field].url,title:o.row[o.field].name,target:"_blank",class:"inline-flex items-center px-3 py-2 text-xs font-medium text-center text-white bg-blue-700 rounded-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800"},[Bs,e.createTextVNode(" Download ")],8,Vs)])):e.createCommentVNode("",!0)])}const $s=k(xs,[["render",Cs]]),Ss={props:["field","row","tdProps"]},Ds={key:0},Ts=["innerHTML"];function Os(t,r,o,a,l,n){return o.row[o.field]?(e.openBlock(),e.createElementBlock("div",Ds,[e.createElementVNode("div",{class:"w-full",innerHTML:o.row[o.field]},null,8,Ts)])):e.createCommentVNode("",!0)}const Ps=k(Ss,[["render",Os]]),js={props:["field","row","tdProps"],computed:{entry(){const[t,r]=this.field.split(".");return e.markRaw({key:t,field:r})},isArray(){return Array.isArray(this.row[this.entry.key])},isObject(){return typeof this.row[this.entry.key]=="object"}}},As={class:"flex flex-wrap gap-2"},Ms={key:1,class:"px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded dark:bg-blue-900 dark:text-blue-300"};function Ls(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",As,[n.isArray?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(o.row[n.entry.key],(i,s)=>(e.openBlock(),e.createElementBlock("span",{key:s,class:"px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded dark:bg-blue-900 dark:text-blue-300"},e.toDisplayString(i[n.entry.field]),1))),128)):n.isObject?(e.openBlock(),e.createElementBlock("span",Ms,e.toDisplayString(o.row[n.entry.key][n.entry.field]),1)):e.createCommentVNode("",!0)])}const Is=k(js,[["render",Ls]]),zs={props:["field","row","tdProps"]},Gs={key:0},Fs={class:"m-1 d-inline-block"},Us=["href","title"],Rs=["src","alt","title"];function qs(t,r,o,a,l,n){return o.row[o.field]?(e.openBlock(),e.createElementBlock("div",Gs,[e.createElementVNode("div",Fs,[e.createElementVNode("a",{href:o.row[o.field].url,title:o.row[o.field].name,target:"_blank"},[e.createElementVNode("img",{src:o.row[o.field].thumbnail,alt:o.row[o.field].name,title:o.row[o.field].name},null,8,Rs)],8,Us)])])):e.createCommentVNode("",!0)}const Hs=k(zs,[["render",qs],["__scopeId","data-v-3a28c02c"]]),Zs={props:["field","row","tdProps"],computed:{isActive(){return this.row[this.field]===1}}},Ks={class:"flex flex-wrap gap-2 text-nowrap"},vs={key:0,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},Ws=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1),Ys={key:1,class:"inline-flex items-center bg-red-100 text-red-800 text-xs font-medium px-2.5 py-0.5 rounded-full dark:bg-red-900 dark:text-red-300"},Xs=e.createElementVNode("span",{class:"w-2 h-2 bg-red-500 rounded-full me-1"},null,-1);function Js(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",Ks,[n.isActive?(e.openBlock(),e.createElementBlock("span",vs,[Ws,e.createTextVNode(" Active ")])):n.isActive?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",Ys,[Xs,e.createTextVNode(" Inactive ")]))])}const Qs=k(Zs,[["render",Js]]),ei={props:["field","row","tdProps"],computed:{hasLabelColor(t){const r=this.tdProps.status_general_labels_color.find(o=>o.label===this.row[this.field]);return r?r.class:""}}},ti={class:"flex flex-wrap gap-2 text-nowrap"},ri={key:0,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},oi=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1),ni={key:1,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-red-800 bg-red-100 rounded-full dark:bg-red-900 dark:text-red-300"},ai=e.createElementVNode("span",{class:"w-2 h-2 bg-red-500 rounded-full me-1"},null,-1),li={key:2,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-yellow-800 bg-yellow-100 rounded-full dark:bg-gray-700 dark:text-yellow-300"},si=e.createElementVNode("span",{class:"w-2 h-2 bg-yellow-500 rounded-full me-1"},null,-1),ii={key:3,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded-full dark:bg-gray-700 dark:text-blue-400"},di=e.createElementVNode("span",{class:"w-2 h-2 bg-blue-500 rounded-full me-1"},null,-1),ci={key:4,class:"inline-flex items-center px-2 py-1 text-sm text-blue-800 bg-blue-100 rounded-full dark:bg-blue-900 dark:text-blue-300"},mi=e.createElementVNode("span",{class:"relative flex w-2 h-2 mr-1"},[e.createElementVNode("span",{class:"absolute inline-flex w-full h-full bg-blue-500 rounded-full animate-ping"}),e.createElementVNode("span",{class:"relative inline-flex w-2 h-2 bg-blue-500 rounded-full"})],-1);function gi(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",ti,[n.hasLabelColor=="green"?(e.openBlock(),e.createElementBlock("span",ri,[oi,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="red"?(e.openBlock(),e.createElementBlock("span",ni,[ai,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="yellow"?(e.openBlock(),e.createElementBlock("span",li,[si,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="default"?(e.openBlock(),e.createElementBlock("span",ii,[di,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="animate"?(e.openBlock(),e.createElementBlock("span",ci,[mi,e.createTextVNode(" "+e.toDisplayString(this.row[this.field]),1)])):e.createCommentVNode("",!0)])}const fi=k(ei,[["render",gi]]),hi={props:["field","row","tdProps"],computed:{hasLabelColor(){return this.tdProps.specfic_color??""},badgeType(){switch(this.tdProps.badge_type){case"Default":return"rounded text-xs";case"Large":return"rounded text-sm ";case"Bordered":return"rounded text-xs border";case"Pills":return"rounded-full text-xs";default:return""}}}},ui={class:"flex flex-wrap gap-2 text-nowrap justify-center"};function pi(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",ui,[n.hasLabelColor=="Default"?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["bg-blue-100 text-blue-800 font-medium me-2 px-2.5 py-0.5 dark:bg-blue-900 dark:text-blue-300 border-blue-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Dark"?(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass(["bg-gray-100 text-gray-800 font-medium me-2 px-2.5 py-0.5 dark:bg-gray-700 dark:text-gray-300 border-gray-500",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Red"?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(["bg-red-100 text-red-800 font-medium me-2 px-2.5 py-0.5 dark:bg-red-900 dark:text-red-300 border-red-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Green"?(e.openBlock(),e.createElementBlock("span",{key:3,class:e.normalizeClass(["bg-green-100 text-green-800 font-medium me-2 px-2.5 py-0.5 dark:bg-green-900 dark:text-green-300 border-green-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Yellow"?(e.openBlock(),e.createElementBlock("span",{key:4,class:e.normalizeClass(["bg-yellow-100 text-yellow-800 font-medium me-2 px-2.5 py-0.5 dark:bg-yellow-900 dark:text-yellow-300 border-yellow-300",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Indigo"?(e.openBlock(),e.createElementBlock("span",{key:5,class:e.normalizeClass(["bg-indigo-100 text-indigo-800 font-medium me-2 px-2.5 py-0.5 dark:bg-indigo-900 dark:text-indigo-300 border-indigo-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Purple"?(e.openBlock(),e.createElementBlock("span",{key:6,class:e.normalizeClass(["bg-purple-100 text-purple-800 font-medium me-2 px-2.5 py-0.5 dark:bg-purple-900 dark:text-purple-300 border-purple-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0),n.hasLabelColor=="Pink"?(e.openBlock(),e.createElementBlock("span",{key:7,class:e.normalizeClass(["bg-pink-100 text-pink-800 font-medium me-2 px-2.5 py-0.5 dark:bg-pink-900 dark:text-pink-300 border-pink-400",n.badgeType])},e.toDisplayString(this.row[this.field]),3)):e.createCommentVNode("",!0)])}const yi=k(hi,[["render",pi]]),bi={props:["field","row","tdProps"],computed:{hasLabelColor(t){const r=this.tdProps.status_general_labels_color.find(o=>o.text===this.row[this.field]);return r?r.class:""},getLabel(){const t=this.tdProps.status_general_labels_color.find(r=>r.text===this.row[this.field]);return t?t.label:""}}},_i={class:"flex flex-wrap gap-2 text-nowrap"},ki={key:0,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},xi=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1),wi={key:1,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-red-800 bg-red-100 rounded-full dark:bg-red-900 dark:text-red-300"},Ei=e.createElementVNode("span",{class:"w-2 h-2 bg-red-500 rounded-full me-1"},null,-1),Ni={key:2,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-yellow-800 bg-yellow-100 rounded-full dark:bg-gray-700 dark:text-yellow-300"},Vi=e.createElementVNode("span",{class:"w-2 h-2 bg-yellow-500 rounded-full me-1"},null,-1),Bi={key:3,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-blue-800 bg-blue-100 rounded-full dark:bg-gray-700 dark:text-blue-400"},Ci=e.createElementVNode("span",{class:"w-2 h-2 bg-blue-500 rounded-full me-1"},null,-1),$i={key:4,class:"inline-flex items-center px-2 py-1 text-sm text-blue-800 bg-blue-100 rounded-full dark:bg-blue-900 dark:text-blue-300"},Si=e.createElementVNode("span",{class:"relative flex w-2 h-2 mr-1"},[e.createElementVNode("span",{class:"absolute inline-flex w-full h-full bg-blue-500 rounded-full animate-ping"}),e.createElementVNode("span",{class:"relative inline-flex w-2 h-2 bg-blue-500 rounded-full"})],-1);function Di(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",_i,[n.hasLabelColor=="green"?(e.openBlock(),e.createElementBlock("span",ki,[xi,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="red"?(e.openBlock(),e.createElementBlock("span",wi,[Ei,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="yellow"?(e.openBlock(),e.createElementBlock("span",Ni,[Vi,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="default"?(e.openBlock(),e.createElementBlock("span",Bi,[Ci,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0),n.hasLabelColor=="animate"?(e.openBlock(),e.createElementBlock("span",$i,[Si,e.createTextVNode(" "+e.toDisplayString(n.getLabel),1)])):e.createCommentVNode("",!0)])}const Ti=k(bi,[["render",Di]]),Oi={props:["field","row","tdProps"],computed:{formattedDate(){if(!this.row[this.field])return"";const t=new Date(this.row[this.field]),r=t.getFullYear(),o=t.toLocaleString("default",{month:"long"}),a=t.getDate();let l=t.getHours();const n=t.getMinutes(),i=t.getSeconds(),s=l>=12?"pm":"am";return l=l%12,l=l||12,`${o} ${a}, ${r}, ${l}:${n}:${i} ${s}`},isActive(){return this.row[this.field]===1}}},Pi={class:"w-full"};function ji(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",Pi,e.toDisplayString(n.formattedDate),1)}const Ai=k(Oi,[["render",ji]]),Mi={props:["field","row","tdProps"]},Li={class:"flex flex-wrap gap-2 text-nowrap"},Ii={key:0,class:"inline-flex items-center px-2 py-1 text-sm text-blue-800 bg-blue-100 rounded-full dark:bg-blue-900 dark:text-blue-300"},zi=e.createElementVNode("span",{class:"relative flex w-2 h-2 mr-1"},[e.createElementVNode("span",{class:"absolute inline-flex w-full h-full bg-blue-500 rounded-full animate-ping"}),e.createElementVNode("span",{class:"relative inline-flex w-2 h-2 bg-blue-500 rounded-full"})],-1),Gi={key:1,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-yellow-800 bg-yellow-100 rounded-full dark:bg-gray-700 dark:text-yellow-300"},Fi=e.createElementVNode("span",{class:"w-2 h-2 bg-yellow-500 rounded-full me-1"},null,-1),Ui={key:2,class:"inline-flex items-center px-2 py-1 text-xs font-medium text-green-800 bg-green-100 rounded-full dark:bg-green-900 dark:text-green-300"},Ri=e.createElementVNode("span",{class:"w-2 h-2 bg-green-500 rounded-full me-1"},null,-1);function qi(t,r,o,a,l,n){return e.openBlock(),e.createElementBlock("div",Li,[o.row[o.field]===0?(e.openBlock(),e.createElementBlock("span",Ii,[zi,e.createTextVNode(" Provisioning")])):e.createCommentVNode("",!0),o.row[o.field]===2?(e.openBlock(),e.createElementBlock("span",Gi,[Fi,e.createTextVNode(" Paused ")])):e.createCommentVNode("",!0),o.row[o.field]===1?(e.openBlock(),e.createElementBlock("span",Ui,[Ri,e.createTextVNode(" Active ")])):e.createCommentVNode("",!0)])}const Hi=k(Mi,[["render",qi]]),Zi={props:["field","row","tdProps"]},Ki={key:0,class:"text-nowrap"},vi={class:"w-full h-full p-3 mx-0 mt-0 overflow-auto font-mono text-left break-words rounded cursor-default whitespace-nowrap console_styles"};function Wi(t,r,o,a,l,n){return o.row[o.field]?(e.openBlock(),e.createElementBlock("div",Ki,[e.createElementVNode("pre",vi," "+e.toDisplayString(o.row[o.field])+`
8
+ `,1)])):e.createCommentVNode("",!0)}const Yi=k(Zi,[["render",Wi]]),Xi={props:["isOpen","title","button_text"],methods:{confirmAction(){this.$emit("confirm-action")},cancelAction(){this.$emit("cancel-action")}}},Ji={key:0,class:"fixed inset-0 z-50 overflow-y-auto",role:"dialog","aria-modal":"true"},Qi={class:"flex items-end justify-center min-h-screen px-4 pt-4 pb-20 text-center sm:block sm:p-0"},ed=e.createElementVNode("div",{class:"fixed inset-0 transition-opacity bg-gray-500 bg-opacity-75","aria-hidden":"true"},null,-1),td=e.createElementVNode("span",{class:"hidden sm:inline-block sm:align-middle sm:h-screen","aria-hidden":"true"},"​",-1),rd={class:"inline-block overflow-hidden text-left align-bottom transition-all transform bg-white rounded-lg shadow-xl sm:my-8 sm:align-middle sm:max-w-lg sm:w-full"},od={class:"px-4 pt-5 pb-4 bg-white sm:p-6 sm:pb-4"},nd={class:"sm:flex sm:items-start"},ad={class:"mt-3 text-center sm:mt-0 sm:ml-4 sm:text-left"},ld={class:"text-lg font-medium leading-6 text-gray-900"},sd={class:"mt-2"},id={class:"px-4 py-3 bg-gray-50 sm:px-6 sm:flex sm:flex-row-reverse"};function dd(t,r,o,a,l,n){return o.isOpen?(e.openBlock(),e.createElementBlock("div",Ji,[e.createElementVNode("div",Qi,[ed,td,e.createElementVNode("div",rd,[e.createElementVNode("div",od,[e.createElementVNode("div",nd,[e.createElementVNode("div",ad,[e.createElementVNode("h3",ld,e.toDisplayString(o.title),1),e.createElementVNode("div",sd,[e.renderSlot(t.$slots,"default")])])])]),e.createElementVNode("div",id,[e.createElementVNode("button",{onClick:r[0]||(r[0]=(...i)=>n.confirmAction&&n.confirmAction(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 text-base font-medium text-white bg-red-600 border border-transparent rounded-md shadow-sm hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm"},e.toDisplayString(o.button_text),1),e.createElementVNode("button",{onClick:r[1]||(r[1]=(...i)=>n.cancelAction&&n.cancelAction(...i)),type:"button",class:"inline-flex justify-center w-full px-4 py-2 mt-3 text-base font-medium text-gray-700 bg-white border border-gray-300 rounded-md shadow-sm hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500 sm:mt-0 sm:ml-3 sm:w-auto sm:text-sm"}," Cancel ")])])])])):e.createCommentVNode("",!0)}const cd=k(Xi,[["render",dd]]),md={class:"w-full"},gd={class:"mb-2 flex justify-between items-center"},fd={class:"text-sm font-medium text-gray-900 dark:text-white"},hd={class:"relative bg-gray-50 rounded-lg dark:bg-gray-700 p-4 h-auto"},ud={class:"overflow-auto max-h-32"},pd={class:"text-sm text-gray-500 dark:text-gray-400"},yd={class:"absolute top-2 end-2 bg-gray-50 dark:bg-gray-700"},bd={key:0,class:"inline-flex items-center"},_d=[e.createElementVNode("svg",{class:"w-3 h-3 me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 18 20"},[e.createElementVNode("path",{d:"M16 1h-3.278A1.992 1.992 0 0 0 11 0H7a1.993 1.993 0 0 0-1.722 1H2a2 2 0 0 0-2 2v15a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2Zm-3 14H5a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2Zm0-4H5a1 1 0 0 1 0-2h8a1 1 0 1 1 0 2Zm0-5H5a1 1 0 0 1 0-2h2V2h4v2h2a1 1 0 1 1 0 2Z"})],-1),e.createElementVNode("span",{class:"text-xs font-semibold"},"Copy",-1)],kd={key:1,class:"inline-flex items-center"},xd=[e.createElementVNode("svg",{class:"w-3 h-3 text-blue-700 dark:text-blue-500 me-2","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 12"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M1 5.917 5.724 10.5 15 1.5"})],-1),e.createElementVNode("span",{class:"text-xs font-semibold text-blue-700 dark:text-blue-500"},"Copied",-1)],wd={class:"mt-2 text-sm text-gray-500 dark:text-gray-400"},Ed={__name:"GlCodeCopy",props:{label_name:{type:String,default:""},code:{type:String,default:""},description:{type:String,default:""}},setup(t){const r=t,o=e.ref(!1),a=n=>{navigator.clipboard.writeText(n).then(function(){o.value=!0,setTimeout(()=>{o.value=!1},2e3)}).catch(function(i){console.error("Error copying to clipboard: ",i)})},l=e.computed(()=>r.code);return(n,i)=>(e.openBlock(),e.createElementBlock("div",md,[e.createElementVNode("div",gd,[e.createElementVNode("p",fd,e.toDisplayString(t.label_name),1)]),e.createElementVNode("div",hd,[e.createElementVNode("div",ud,[e.createElementVNode("code",pd,e.toDisplayString(l.value),1)]),e.createElementVNode("div",yd,[e.createElementVNode("button",{onClick:i[0]||(i[0]=s=>a(l.value)),class:"text-gray-900 dark:text-gray-400 m-1 hover:bg-gray-100 dark:bg-gray-800 dark:border-gray-600 dark:hover:bg-gray-700 rounded-lg py-2 px-3 inline-flex items-center justify-center bg-white border-gray-200 border"},[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",bd,_d)),o.value?(e.openBlock(),e.createElementBlock("span",kd,xd)):e.createCommentVNode("",!0)])])]),e.createElementVNode("p",wd,e.toDisplayString(t.description),1)]))}},Nd={class:"w-full"},Vd={class:"flex justify-between items-center"},Bd={class:"gl-label-form"},Cd={class:"flex items-center"},$d={class:"flex-shrink-0 z-10 inline-flex items-center p-2 text-sm font-medium text-center text-gray-900 bg-gray-100 border border-gray-300 rounded-s-lg dark:bg-gray-600 dark:text-white dark:border-gray-600"},Sd={class:"relative w-full"},Dd=["value"],Td={key:0},Od=[e.createElementVNode("svg",{class:"w-4 h-4","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 18 20"},[e.createElementVNode("path",{d:"M16 1h-3.278A1.992 1.992 0 0 0 11 0H7a1.993 1.993 0 0 0-1.722 1H2a2 2 0 0 0-2 2v15a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V3a2 2 0 0 0-2-2Zm-3 14H5a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2Zm0-4H5a1 1 0 0 1 0-2h8a1 1 0 1 1 0 2Zm0-5H5a1 1 0 0 1 0-2h2V2h4v2h2a1 1 0 1 1 0 2Z"})],-1)],Pd={key:1,class:"inline-flex items-center"},jd=[e.createElementVNode("svg",{class:"w-4 h-4","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 12"},[e.createElementVNode("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M1 5.917 5.724 10.5 15 1.5"})],-1)],Ad={class:"mt-2 text-sm text-gray-500 dark:text-gray-400"},Md={__name:"GlTextCopy",props:{label_name:{type:String,default:""},text_name:{type:String,default:""},code:{type:String,default:""},description:{type:String,default:""}},setup(t){const r=t,o=e.ref(!1),a=n=>{navigator.clipboard.writeText(n).then(function(){o.value=!0,setTimeout(()=>{o.value=!1},2e3)}).catch(function(i){console.error("Error copying to clipboard: ",i)})},l=e.computed(()=>r.code);return(n,i)=>(e.openBlock(),e.createElementBlock("div",Nd,[e.createElementVNode("div",Vd,[e.createElementVNode("label",Bd,e.toDisplayString(t.label_name),1)]),e.createElementVNode("div",Cd,[e.createElementVNode("span",$d,e.toDisplayString(t.text_name),1),e.createElementVNode("div",Sd,[e.createElementVNode("input",{type:"text","aria-describedby":"helper-text-explanation",class:"bg-gray-50 border border-e-0 border-gray-300 text-gray-500 dark:text-gray-400 text-sm border-s-0 focus:ring-blue-500 focus:border-blue-500 block w-full p-2 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:focus:ring-blue-500 dark:focus:border-blue-500",value:l.value,readonly:"",disabled:""},null,8,Dd)]),e.createElementVNode("button",{style:{padding:".61rem"},onClick:i[0]||(i[0]=s=>a(l.value)),class:"flex-shrink-0 z-10 inline-flex items-center px-4 text-sm font-medium text-center text-white bg-blue-700 rounded-e-lg hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800 border border-blue-700 dark:border-blue-600 hover:border-blue-800 dark:hover:border-blue-700",type:"button"},[o.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("span",Td,Od)),o.value?(e.openBlock(),e.createElementBlock("span",Pd,jd)):e.createCommentVNode("",!0)])]),e.createElementVNode("p",Ad,e.toDisplayString(t.description),1)]))}};p.DatatableStatusTextLabelGeneral=Ti,p.GLDatatableCommand=Yi,p.GLDatatableDateTime=Ai,p.GLDatatableStatusServer=Hi,p.GlButton=wr,p.GlCard=er,p.GlCodeCopy=Ed,p.GlConfirmationModal=cd,p.GlDataTable=Il,p.GlDataTableServerSide=el,p.GlDatatableAction=as,p.GlDatatableDeleteAction=gs,p.GlDatatableFileDownload=ks,p.GlDatatableFiles=$s,p.GlDatatableHtml=Ps,p.GlDatatableList=Is,p.GlDatatablePicture=Hs,p.GlDatatableStatus=Qs,p.GlDatatableStatusGeneral=fi,p.GlDatatableStatusSpecficColor=yi,p.GlDeleteConfirmationModal=G,p.GlDropdown=sa,p.GlFilesUpload=Mt,p.GlLanguageSelector=Wt,p.GlModal=Nn,p.GlMultiItemSlide=yn,p.GlMultiSelectDropdown=br,p.GlNotify=Rt,p.GlTab=No,p.GlTabsWrapper=ko,p.GlTailwindPagination=Ve,p.GlTextCopy=Md,p.GlTextInput=co,p.GlTextTranslate=to,p.GlTextarea=ua,p.GlTextareaTranslate=Pr,p.GlTinymceTranslate=qr,p.GlToast=J,p.GlToastList=Wl,p.GlToggleBox=In,Object.defineProperty(p,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -19,7 +19,7 @@
19
19
 
20
20
  },
21
21
  "private": false,
22
- "version": "1.0.120",
22
+ "version": "1.0.122",
23
23
  "scripts": {
24
24
  "dev": "vite",
25
25
  "build": "vite build",